aboutsummaryrefslogtreecommitdiffstats
path: root/include/items.php
diff options
context:
space:
mode:
authorHabeas Codice <habeascodice@federated.social>2014-11-22 11:54:40 -0800
committerHabeas Codice <habeascodice@federated.social>2014-11-22 11:54:40 -0800
commitab5bf1b7d69f4027f595eef56cf4d99207b8b46e (patch)
tree2ba7b846d1b394f680a57bf61e4d6a9c09182e62 /include/items.php
parentecb86dd6b20adf2e7587e5b16f8eb7cd7b8f1b68 (diff)
downloadvolse-hubzilla-ab5bf1b7d69f4027f595eef56cf4d99207b8b46e.tar.gz
volse-hubzilla-ab5bf1b7d69f4027f595eef56cf4d99207b8b46e.tar.bz2
volse-hubzilla-ab5bf1b7d69f4027f595eef56cf4d99207b8b46e.zip
prevent database hackery from leaking over the wire
Diffstat (limited to 'include/items.php')
-rwxr-xr-xinclude/items.php3
1 files changed, 2 insertions, 1 deletions
diff --git a/include/items.php b/include/items.php
index 477b5197e..c488e1953 100755
--- a/include/items.php
+++ b/include/items.php
@@ -1094,7 +1094,8 @@ function encode_item($item,$mirror = false) {
$x['message_parent'] = $item['thr_parent'];
$x['created'] = $item['created'];
$x['edited'] = $item['edited'];
- $x['expires'] = $item['expires'];
+ // always send 0's over the wire
+ $x['expires'] = (($item['expires'] == '0001-01-01 00:00:00') ? '0000-00-00 00:00:00' : $item['expires']);
$x['commented'] = $item['commented'];
$x['mimetype'] = $item['mimetype'];
$x['title'] = $item['title'];