File tree Expand file tree Collapse file tree 2 files changed +8
-2
lines changed
Expand file tree Collapse file tree 2 files changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -71,7 +71,10 @@ public function prepareFields(array $content): array
7171 }
7272 }
7373
74- $ translates = sLangContent::whereResource ($ content ['id ' ] ?? 0 )->get ()->toArray ();
74+ $ translates = sLangContent::withoutGlobalScope ('language ' )
75+ ->whereResource ($ content ['id ' ] ?? 0 )
76+ ->get ()
77+ ->toArray ();
7578
7679 if (is_array ($ translates ) && count ($ translates )) {
7780 foreach ($ translates as $ translate ) {
Original file line number Diff line number Diff line change @@ -222,7 +222,10 @@ public function isMultilangTv($id): bool
222222 */
223223 public function getLangContent (int $ resourceId , string $ langKey ): array
224224 {
225- $ sLangContent = sLangContent::whereResource ($ resourceId )->whereLang ($ langKey )->first ();
225+ $ sLangContent = sLangContent::withoutGlobalScope ('language ' )
226+ ->whereResource ($ resourceId )
227+ ->whereLang ($ langKey )
228+ ->first ();
226229 return $ sLangContent ? $ sLangContent ->toArray () : [];
227230 }
228231
You can’t perform that action at this time.
0 commit comments