@@ 93-95 (lines=3) @@ | ||
90 | $query = CommentPost::where('pathway', '=', $path); |
|
91 | ||
92 | // check if comments is depend of language locale |
|
93 | if ((int)$configs['onlyLocale'] === 1) { |
|
94 | $query = $query->where('lang', '=', App::$Request->getLanguage()); |
|
95 | } |
|
96 | ||
97 | // get comments with offset and limit |
|
98 | $records = $query->skip($offset) |
|
@@ 151-153 (lines=3) @@ | ||
148 | ||
149 | // get data from db by comment id |
|
150 | $records = CommentAnswer::where('comment_id', '=', $commentId); |
|
151 | if ((int)$configs['onlyLocale'] === 1) { |
|
152 | $records = $records->where('lang', '=', App::$Request->getLanguage()); |
|
153 | } |
|
154 | ||
155 | // check objects count |
|
156 | if ($records->count() < 1) { |