From ac7f1ba03d7f8349498a5c2cfc8035f82a2729c9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20T=C3=A4nzer?= Date: Thu, 29 Apr 2010 20:49:27 +0200 Subject: [PATCH] Class constants have to be prefixed with self:: in PHP MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Michael Tänzer --- .../application/controllers/AddPointsController.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/manager/application/controllers/AddPointsController.php b/manager/application/controllers/AddPointsController.php index 95b1d5f..1b3380b 100644 --- a/manager/application/controllers/AddPointsController.php +++ b/manager/application/controllers/AddPointsController.php @@ -90,17 +90,17 @@ class AddPointsController extends Zend_Controller_Action $points = $values['quantity']; do { // split up into multiple assurances - if ($points > MAX_POINTS_PER_ASSURANCE) { - $assurance['awarded'] = MAX_POINTS_PER_ASSURANCE; - $points -= MAX_POINTS_PER_ASSURANCE; + if ($points > self::MAX_POINTS_PER_ASSURANCE) { + $assurance['awarded'] = self::MAX_POINTS_PER_ASSURANCE; + $points -= self::MAX_POINTS_PER_ASSURANCE; } else { $assurance['awarded'] = $points; $points = 0; } // only assign points whithin the limit - if ($user['points'] + $assurance['awarded'] > MAX_ASSURANCE_POINTS){ - $assurance['points'] = MAX_ASSURANCE_POINTS - $user['points']; + if ($user['points'] + $assurance['awarded'] > self::MAX_ASSURANCE_POINTS){ + $assurance['points'] = self::MAX_ASSURANCE_POINTS - $user['points']; } else { $assurance['points'] = $assurance['awarded']; }