Clean up misuse of wfTimestampOrNull()
authorTimo Tijhof <krinklemail@gmail.com>
Fri, 23 Sep 2016 23:59:56 +0000 (00:59 +0100)
committerAaron Schulz <aschulz@wikimedia.org>
Sat, 24 Sep 2016 00:09:51 +0000 (00:09 +0000)
commit1b462e24f6565c6202c65f6fd2fcb2dcbdf7980e
tree94d3330a5dc3ad1bc4bcb25d082fe6c78a2d02e8
parent305499a998c763f1ec9bf5c203708b4200d06747
Clean up misuse of wfTimestampOrNull()

It's primarily meant for nullable timestamps in the database.
And for the mere purpose of an is_null() check, it's more confusion
than useful to cause this function since in these two cases its return
value is not used as-is but further conditionalized.

* Also fix fragile link between getRegistration()'s false return
  value never being passed to wfTimestamp (to mean "now") because
  of the isLoggedIn() guard. The ternary would now make those
  follow the 'else' branch toward null.

Change-Id: I9a1ee2a56e1767bfb750e27b1f37bdaeb5e6378d
includes/OutputPage.php
includes/filerepo/ForeignAPIRepo.php