Browse Source

Fix PM\PBlock model

Visman 3 years ago
parent
commit
493256a9a8
1 changed files with 2 additions and 2 deletions
  1. 2 2
      app/Models/PM/PBlock.php

+ 2 - 2
app/Models/PM/PBlock.php

@@ -56,8 +56,8 @@ class PBlock extends Model
         while ($row = $stmt->fetch()) {
             if ($row['bl_first_id'] === $user->id) {
                 $this->repository[$user->id][$row['bl_second_id']] = $row['bl_second_id'];
-            } elseif ($row['bl_second_id'] !== $user->id) {
-                $this->repository[$row['bl_second_id']] = true;
+            } else {
+                $this->repository[$row['bl_first_id']] = true;
             }
         }
     }