From: Ori Livneh Date: Sat, 3 May 2014 18:30:05 +0000 (-0700) Subject: JSON RC format: cast 'patrolled' and 'minor' to boolean X-Git-Tag: 1.31.0-rc.0~15904 X-Git-Url: https://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/banques/?a=commitdiff_plain;h=1f3f032f2a34d56436b6f66147e58f6aa847c0ca;p=lhc%2Fweb%2Fwiklou.git JSON RC format: cast 'patrolled' and 'minor' to boolean This makes them consistent with 'bot'. Change-Id: Id4342eedee8176b0b76458bdaf8ca69c89857d47 --- diff --git a/includes/rcfeed/MachineReadableRCFeedFormatter.php b/includes/rcfeed/MachineReadableRCFeedFormatter.php index 9321f52bc2..e5077a291b 100644 --- a/includes/rcfeed/MachineReadableRCFeedFormatter.php +++ b/includes/rcfeed/MachineReadableRCFeedFormatter.php @@ -63,9 +63,9 @@ abstract class MachineReadableRCFeedFormatter implements RCFeedFormatter { if ( $type == RC_EDIT || $type == RC_NEW ) { global $wgUseRCPatrol, $wgUseNPPatrol; - $packet['minor'] = $attrib['rc_minor']; + $packet['minor'] = (bool)$attrib['rc_minor']; if ( $wgUseRCPatrol || ( $type == RC_NEW && $wgUseNPPatrol ) ) { - $packet['patrolled'] = $attrib['rc_patrolled']; + $packet['patrolled'] = (bool)$attrib['rc_patrolled']; } }