Completed
Push — work-fleets ( ce5b3a...e12dae )
by SuperNova.WS
05:40
created
includes/classes/Buddy.php 1 patch
Doc Comments   +4 added lines patch added patch discarded remove patch
@@ -6,6 +6,10 @@
 block discarded – undo
6 6
   public static $idField = 'BUDDY_ID';
7 7
 
8 8
   // TODO - remove public static function db_buddy_update_status($buddy_id, $status) {
9
+
10
+  /**
11
+   * @param integer $status
12
+   */
9 13
   public function db_buddy_update_status($status) {
10 14
     $buddy_id = idval($this->row['BUDDY_ID']);
11 15
 
Please login to merge, or discard this patch.
includes/classes/DbRowSimple.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -13,7 +13,7 @@  discard block
 block discarded – undo
13 13
       ->setIdField($object::$idField)
14 14
       ->field('*')
15 15
       ->from($object::$tableName)
16
-      ->where($object::$idField . ' = "' . $rowId . '"');
16
+      ->where($object::$idField.' = "'.$rowId.'"');
17 17
 
18 18
     $object->row = $stmt->selectRow();
19 19
 
@@ -24,7 +24,7 @@  discard block
 block discarded – undo
24 24
    * @param Entity $object
25 25
    */
26 26
   public function deleteById($object) {
27
-    classSupernova::$gc->db->doquery("DELETE FROM `{{" . $object::$tableName . "}}` WHERE `{$object::$idField}` = '{$object->row[$object::$idField]}' LIMIT 1;");
27
+    classSupernova::$gc->db->doquery("DELETE FROM `{{".$object::$tableName."}}` WHERE `{$object::$idField}` = '{$object->row[$object::$idField]}' LIMIT 1;");
28 28
 
29 29
     return classSupernova::$gc->db->db_affected_rows();
30 30
   }
Please login to merge, or discard this patch.
includes/classes/Entity.php 1 patch
Spacing   +3 added lines, -3 removed lines patch added patch discarded remove patch
@@ -35,18 +35,18 @@
 block discarded – undo
35 35
   // TODO - move to reader ????????
36 36
   public function insert() {
37 37
     $query = array();
38
-    foreach($this->row as $fieldName => $fieldValue) {
38
+    foreach ($this->row as $fieldName => $fieldValue) {
39 39
       $fieldValue = self::$dbStatic->db_escape($fieldValue);
40 40
       $query[] = "`{$fieldName}` = '{$fieldValue}'";
41 41
     }
42 42
 
43 43
     $query = implode(',', $query);
44
-    if(empty($query)) {
44
+    if (empty($query)) {
45 45
       // TODO Exceptiion
46 46
       return 0;
47 47
     }
48 48
 
49
-    self::$dbStatic->doquery("INSERT INTO `{{" . static::$tableName . "}}` SET " . $query);
49
+    self::$dbStatic->doquery("INSERT INTO `{{".static::$tableName."}}` SET ".$query);
50 50
 
51 51
     // TODO Exceptiion if result is empty
52 52
     return $this->row[static::$idField] = self::$dbStatic->db_insert_id();
Please login to merge, or discard this patch.
buddy.php 1 patch
Spacing   +2 added lines, -2 removed lines patch added patch discarded remove patch
@@ -9,7 +9,7 @@  discard block
 block discarded – undo
9 9
  *
10 10
  * Idea from buddy.php Created by Perberos. All rights reversed (C) 2006
11 11
  * */
12
-include('common.' . substr(strrchr(__FILE__, '.'), 1));
12
+include('common.'.substr(strrchr(__FILE__, '.'), 1));
13 13
 
14 14
 class_exists('Buddy');
15 15
 
@@ -52,7 +52,7 @@  discard block
 block discarded – undo
52 52
   // Checking for user ID - in case if it was request from outside buddy system
53 53
   $new_friend_id_safe = sys_get_param_id('request_user_id');
54 54
   $new_friend_name = sys_get_param_str_unsafe('request_user_name');
55
-  if($new_friend_id_safe || $new_friend_name) {
55
+  if ($new_friend_id_safe || $new_friend_name) {
56 56
     sn_db_transaction_start();
57 57
     $buddy = classSupernova::$gc->buddy;
58 58
     $new_request_text = sys_get_param_str('request_text');
Please login to merge, or discard this patch.