define ( 'FRIENDICA_CODENAME', 'Asparagus');
define ( 'FRIENDICA_VERSION', '3.5-dev' );
define ( 'DFRN_PROTOCOL_VERSION', '2.23' );
-define ( 'DB_UPDATE_VERSION', 1196 );
+define ( 'DB_UPDATE_VERSION', 1197 );
/**
* @brief Constant with a HTML line break.
-- ------------------------------------------
-- Friendica 3.5-dev (Asparagus)
--- DB_UPDATE_VERSION 1196
+-- DB_UPDATE_VERSION 1197
-- ------------------------------------------
`commented` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
`received` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
`changed` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
+ `owner-id` int(11) NOT NULL DEFAULT 0,
`owner-name` varchar(255) NOT NULL DEFAULT '',
`owner-link` varchar(255) NOT NULL DEFAULT '',
`owner-avatar` varchar(255) NOT NULL DEFAULT '',
+ `author-id` int(11) NOT NULL DEFAULT 0,
`author-name` varchar(255) NOT NULL DEFAULT '',
`author-link` varchar(255) NOT NULL DEFAULT '',
`author-avatar` varchar(255) NOT NULL DEFAULT '',
"commented" => array("type" => "datetime", "not null" => "1", "default" => "0000-00-00 00:00:00"),
"received" => array("type" => "datetime", "not null" => "1", "default" => "0000-00-00 00:00:00"),
"changed" => array("type" => "datetime", "not null" => "1", "default" => "0000-00-00 00:00:00"),
+ "owner-id" => array("type" => "int(11)", "not null" => "1", "default" => "0"),
"owner-name" => array("type" => "varchar(255)", "not null" => "1", "default" => ""),
"owner-link" => array("type" => "varchar(255)", "not null" => "1", "default" => ""),
"owner-avatar" => array("type" => "varchar(255)", "not null" => "1", "default" => ""),
+ "author-id" => array("type" => "int(11)", "not null" => "1", "default" => "0"),
"author-name" => array("type" => "varchar(255)", "not null" => "1", "default" => ""),
"author-link" => array("type" => "varchar(255)", "not null" => "1", "default" => ""),
"author-avatar" => array("type" => "varchar(255)", "not null" => "1", "default" => ""),
"photo" => $arr['author-avatar'], "name" => $arr['author-name']));
}
+ if ($arr["author-id"] == 0)
+ $arr["author-id"] = get_contact($arr["author-link"], 0);
+
+ if ($arr["owner-id"] == 0)
+ $arr["owner-id"] = get_contact($arr["owner-link"], 0);
+
if ($arr['guid'] != "") {
// Checking if there is already an item with the same guid
logger('checking for an item for user '.$arr['uid'].' on network '.$arr['network'].' with the guid '.$arr['guid'], LOGGER_DEBUG);
<?php
-define('UPDATE_VERSION' , 1196);
+define('UPDATE_VERSION' , 1197);
/**
*