File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Http/Controllers/Operations Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -82,7 +82,7 @@ public function edit($id)
8282 /**
8383 * Update the specified resource in the database.
8484 *
85- * @return array |\Illuminate\Http\RedirectResponse
85+ * @return \Illuminate\Http\JsonResponse |\Illuminate\Http\RedirectResponse
8686 */
8787 public function update ()
8888 {
Original file line number Diff line number Diff line change @@ -321,7 +321,7 @@ public function setSaveAction($forceSaveAction = null)
321321 * Redirect to the correct URL, depending on which save action has been selected.
322322 *
323323 * @param string $itemId
324- * @return array |\Illuminate\Http\RedirectResponse
324+ * @return \Illuminate\Http\JsonResponse |\Illuminate\Http\RedirectResponse
325325 */
326326 public function performSaveAction ($ itemId = null )
327327 {
@@ -345,12 +345,12 @@ public function performSaveAction($itemId = null)
345345
346346 // if the request is AJAX, return a JSON response
347347 if ($ this ->getRequest ()->ajax ()) {
348- return [
348+ return response ()-> json ( [
349349 'success ' => true ,
350350 'data ' => $ this ->entry ,
351351 'redirect_url ' => $ redirectUrl ,
352352 'referrer_url ' => $ referrer_url ?? false ,
353- ];
353+ ]) ;
354354 }
355355
356356 if (isset ($ referrer_url )) {
You can’t perform that action at this time.
0 commit comments