Browse Source

Update code comments

Visman 4 years ago
parent
commit
f6cef733d9

+ 1 - 0
app/Models/AdminList/Model.php

@@ -11,6 +11,7 @@ class Model extends ParentModel
 {
     /**
      * Загружает список id админов из кеша/БД
+     * Создает кеш
      */
     public function init(): Model
     {

+ 1 - 2
app/Models/BanList/Load.php

@@ -11,8 +11,7 @@ use RuntimeException;
 class Load extends Method
 {
     /**
-     * Загружает список банов из БД
-     * Создает кеш
+     * Загружает список банов из БД для модели и кеша
      */
     public function load(): array
     {

+ 1 - 0
app/Models/BanList/Model.php

@@ -11,6 +11,7 @@ class Model extends ParentModel
 {
     /**
      * Загружает список банов из кеша/БД
+     * Создает кеш
      */
     public function init(): Model
     {

+ 1 - 0
app/Models/Censorship/Model.php

@@ -11,6 +11,7 @@ class Model extends ParentModel
 {
     /**
      * Загружает список цензуры из кеша/БД
+     * Создает кеш
      */
     public function init(): Model
     {

+ 2 - 2
app/Models/Censorship/Refresh.php

@@ -9,8 +9,7 @@ use ForkBB\Models\Method;
 class Refresh extends Method
 {
     /**
-     * Заполняет модель данными из БД
-     * Создает кеш
+     * Загружает данные из БД для модели и кеша
      */
     public function refresh(): array
     {
@@ -20,6 +19,7 @@ class Refresh extends Method
         $stmt    = $this->c->DB->query($query);
         $search  = [];
         $replace = [];
+
         while ($row = $stmt->fetch()) {
             $search[$row['id']]  = '%(?<![\p{L}\p{N}])('
                 . \str_replace('\*', '[\p{L}\p{N}]*?', \preg_quote($row['search_for'], '%'))

+ 1 - 2
app/Models/Config/Load.php

@@ -12,8 +12,7 @@ use RuntimeException;
 class Load extends Method
 {
     /**
-     * Заполняет модель данными из БД
-     * Создает кеш
+     * Загружает данные из БД для модели и кеша
      */
     public function load(): array
     {

+ 1 - 0
app/Models/Config/Model.php

@@ -11,6 +11,7 @@ class Model extends DataModel
 {
     /**
      * Заполняет модель данными из кеша/БД
+     * Создает кеш
      */
     public function init(): Model
     {

+ 1 - 0
app/Models/Report/Manager.php

@@ -73,6 +73,7 @@ class Manager extends ManagerModel
 
     /**
      * Id последнего репорта
+     * Создает кеш
      */
     public function lastId(): int
     {

+ 1 - 1
app/Models/SmileyList/Load.php

@@ -10,7 +10,7 @@ use PDO;
 class Load extends Method
 {
     /**
-     * Загружает данные из БД
+     * Загружает данные из БД для модели и кеша
      */
     public function load(): array
     {