solved issuis from Bulk Review v3,v4

This commit is contained in:
Milos Holba
2020-12-19 15:12:56 +01:00
parent 55cf58fffd
commit 65624326c7
17 changed files with 195 additions and 111 deletions

View File

@@ -96,16 +96,16 @@ class ShareController extends Controller
*/
public function destroy(Request $request)
{
foreach($request->input('tokens') as $folder) {
foreach($request->input('tokens') as $token) {
// Get sharing record
Share::where('token', $folder['token'])
Share::where('token', $token)
->where('user_id', Auth::id())
->firstOrFail()
->delete();
// Get zip record
$zip = Zip::where('shared_token', $folder['token'])
$zip = Zip::where('shared_token', $token)
->where('user_id', Auth::id())
->first();