@@ -47,8 +47,8 @@ |
||
| 47 | 47 | public function scopePopular($query, $type = null) |
| 48 | 48 | { |
| 49 | 49 | $query->select('followable_id', 'followable_type', \DB::raw('COUNT(*) AS count')) |
| 50 | - ->groupBy('followable_id', 'followable_type') |
|
| 51 | - ->orderByDesc('count'); |
|
| 50 | + ->groupBy('followable_id', 'followable_type') |
|
| 51 | + ->orderByDesc('count'); |
|
| 52 | 52 | |
| 53 | 53 | if ($type) { |
| 54 | 54 | $query->where('followable_type', $this->normalizeFollowableType($type)); |