mirror of
https://github.com/friendica/friendica
synced 2025-04-28 21:44:22 +02:00
Replace include/event function with method calls
- Updated scope of Model\Event methods - Updated use list
This commit is contained in:
parent
5aecc758f9
commit
f7e2071117
7 changed files with 55 additions and 53 deletions
|
@ -19,11 +19,11 @@ use Friendica\Core\System;
|
|||
use Friendica\Core\Worker;
|
||||
use Friendica\Database\DBM;
|
||||
use Friendica\Model\Contact;
|
||||
use Friendica\Model\Event;
|
||||
use Friendica\Model\GContact;
|
||||
use Friendica\Model\Group;
|
||||
use Friendica\Model\Item;
|
||||
use Friendica\Model\Profile;
|
||||
use Friendica\Model\Term;
|
||||
use Friendica\Model\User;
|
||||
use Friendica\Object\Image;
|
||||
use Friendica\Protocol\OStatus;
|
||||
|
@ -2614,7 +2614,7 @@ class DFRN
|
|||
// Is it an event?
|
||||
if ($item["object-type"] == ACTIVITY_OBJ_EVENT) {
|
||||
logger("Item ".$item["uri"]." seems to contain an event.", LOGGER_DEBUG);
|
||||
$ev = bbtoevent($item["body"]);
|
||||
$ev = Event::fromBBCode($item["body"]);
|
||||
if ((x($ev, "desc") || x($ev, "summary")) && x($ev, "start")) {
|
||||
logger("Event in item ".$item["uri"]." was found.", LOGGER_DEBUG);
|
||||
$ev["cid"] = $importer["id"];
|
||||
|
@ -2633,7 +2633,7 @@ class DFRN
|
|||
$ev["id"] = $r[0]["id"];
|
||||
}
|
||||
|
||||
$event_id = event_store($ev);
|
||||
$event_id = Event::store($ev);
|
||||
logger("Event ".$event_id." was stored", LOGGER_DEBUG);
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue