Pārlūkot izejas kodu

Fix whitespace characters in code

Visman 5 gadi atpakaļ
vecāks
revīzija
f85405c48e
3 mainītis faili ar 10 papildinājumiem un 10 dzēšanām
  1. 7 7
      app/Core/DB/mysql.php
  2. 1 1
      app/Core/Secury.php
  3. 2 2
      app/Models/Post/View.php

+ 7 - 7
app/Core/DB/mysql.php

@@ -171,8 +171,8 @@ class Mysql
      *
      * @return bool
      */
-	public function fieldExists($table, $field, $noPrefix = false)
-	{
+    public function fieldExists($table, $field, $noPrefix = false)
+    {
         $table = ($noPrefix ? '' : $this->dbPrefix) . $table;
         try {
             $stmt = $this->db->query('SELECT 1 FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_SCHEMA = DATABASE() AND TABLE_NAME = ?s:table AND COLUMN_NAME = ?s:field', [':table' => $table, ':field' => $field]);
@@ -182,7 +182,7 @@ class Mysql
             return false;
         }
         return ! empty($result);
-	}
+    }
 
     /**
      * Проверяет наличие индекса в таблице
@@ -301,7 +301,7 @@ class Mysql
     {
         $table = ($noPrefix ? '' : $this->dbPrefix) . $table;
         $this->testStr($table);
-		return $this->db->exec("DROP TABLE IF EXISTS `{$table}`") !== false;
+        return $this->db->exec("DROP TABLE IF EXISTS `{$table}`") !== false;
     }
 
     /**
@@ -371,8 +371,8 @@ class Mysql
      *
      * @return bool
      */
-	public function alterField($table, $field, $type, $allowNull, $default = null, $after = null, $noPrefix = false)
-	{
+    public function alterField($table, $field, $type, $allowNull, $default = null, $after = null, $noPrefix = false)
+    {
         $table = ($noPrefix ? '' : $this->dbPrefix) . $table;
         $this->testStr($table);
         $this->testStr($field);
@@ -388,7 +388,7 @@ class Mysql
             $query .= " AFTER `{$after}`";
         }
         return $this->db->exec($query) !== false;
-	}
+    }
 
     /**
      * Удаляет поле из таблицы

+ 1 - 1
app/Core/Secury.php

@@ -90,7 +90,7 @@ class Secury
         if (\strlen($key) < $len) {
             throw new RuntimeException('Could not gather sufficient random data');
         }
-    	return $key;
+        return $key;
     }
 
     /**

+ 2 - 2
app/Models/Post/View.php

@@ -191,9 +191,9 @@ class View extends Action
 
         if ($arg instanceof Topic) {
             foreach ($result as $post) {
-				if ($post->id === $arg->last_post_id) { // время последнего сообщения в теме может равняться 
+                if ($post->id === $arg->last_post_id) { // время последнего сообщения в теме может равняться 
                     $timeMax = $arg->last_post;         // времени его редактирования, а не создания
-				} elseif ($post->posted > $timeMax) {
+                } elseif ($post->posted > $timeMax) {
                     $timeMax = $post->posted;
                 }
                 if ($post->id === $arg->first_post_id && $offset > 0) {