1
0
Fork 0

Update false evaluations

=== false and !== false to is_null where appropriate.
This commit is contained in:
Adam Magness 2017-12-06 14:57:06 -05:00
commit cadfef63c4
7 changed files with 13 additions and 9 deletions

View file

@ -23,13 +23,15 @@ class Feature
{
$x = Config::get('feature_lock', $feature, false);
if ($x === false) {
if (is_null($x)) {
$x = PConfig::get($uid, 'feature', $feature, false);
}
if ($x === false) {
if (is_null($x)) {
$x = Config::get('feature', $feature, false);
}
if ($x === false) {
if (is_null($x)) {
$x = self::getDefault($feature);
}

View file

@ -171,7 +171,7 @@ class FKOAuthDataStore extends OAuthDataStore
dba::delete('tokens', array('id' => $token->key));
if (!is_null($ret) && $uverifier !== false) {
if (!is_null($ret) && !is_null($uverifier)) {
Config::delete("oauth", $verifier);
}

View file

@ -92,7 +92,7 @@ Class OnePoll
if ($contact['subhub']) {
$poll_interval = Config::get('system', 'pushpoll_frequency');
$contact['priority'] = (($poll_interval !== false) ? intval($poll_interval) : 3);
$contact['priority'] = ((!is_null($poll_interval)) ? intval($poll_interval) : 3);
$hub_update = false;
if (datetime_convert('UTC', 'UTC', 'now') > datetime_convert('UTC', 'UTC', $t . " + 1 day")) {