Merge pull request #4621 from annando/not-null
Avoid storing "null" values
This commit is contained in:
commit
e970bbdca8
|
@ -2079,8 +2079,8 @@ class DFRN
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
$fields = ['title' => $item["title"], 'body' => $item["body"],
|
$fields = ['title' => defaults($item, 'title', ''), 'body' => defaults($item, 'body', ''),
|
||||||
'tag' => $item["tag"], 'changed' => DateTimeFormat::utcNow(),
|
'tag' => defaults($item, 'tag', ''), 'changed' => DateTimeFormat::utcNow(),
|
||||||
'edited' => DateTimeFormat::utc($item["edited"])];
|
'edited' => DateTimeFormat::utc($item["edited"])];
|
||||||
|
|
||||||
$condition = ["`uri` = ? AND `uid` IN (0, ?)", $item["uri"], $importer["importer_uid"]];
|
$condition = ["`uri` = ? AND `uid` IN (0, ?)", $item["uri"], $importer["importer_uid"]];
|
||||||
|
|
|
@ -1302,7 +1302,7 @@ class PortableContact
|
||||||
if (isset($data->version)) {
|
if (isset($data->version)) {
|
||||||
$network = NETWORK_DFRN;
|
$network = NETWORK_DFRN;
|
||||||
|
|
||||||
$noscrape = $data->no_scrape_url;
|
$noscrape = defaults($data->no_scrape_url, '');
|
||||||
$version = $data->version;
|
$version = $data->version;
|
||||||
$site_name = $data->site_name;
|
$site_name = $data->site_name;
|
||||||
$info = $data->info;
|
$info = $data->info;
|
||||||
|
|
Loading…
Reference in a new issue