Find this useful? Enter your email to receive occasional updates for securing PHP code.

Signing you up...

Thank you for signing up!

PHP Decode

<?php namespace App\Http\Controllers\API; use App\Http\Controllers\Controller; use App\H..

Decoded Output download

<?php

namespace App\Http\Controllers\API;

use App\Http\Controllers\Controller;
use App\Http\Requests\API\PlaylistFolderPlaylistDestroyRequest;
use App\Http\Requests\API\PlaylistFolderPlaylistStoreRequest;
use App\Models\PlaylistFolder;
use App\Services\PlaylistFolderService;
use Illuminate\Support\Arr;

class PlaylistFolderPlaylistController extends Controller
{
    public function __construct(private PlaylistFolderService $service)
    {
    }

    public function store(PlaylistFolder $playlistFolder, PlaylistFolderPlaylistStoreRequest $request)
    {
        $this->authorize('own', $playlistFolder);

        $this->service->addPlaylistsToFolder($playlistFolder, Arr::wrap($request->playlists));

        return response()->noContent();
    }

    public function destroy(PlaylistFolder $playlistFolder, PlaylistFolderPlaylistDestroyRequest $request)
    {
        $this->authorize('own', $playlistFolder);

        $this->service->movePlaylistsToRootLevel(Arr::wrap($request->playlists));

        return response()->noContent();
    }
}
 ?>

Did this file decode correctly?

Original Code

<?php

namespace App\Http\Controllers\API;

use App\Http\Controllers\Controller;
use App\Http\Requests\API\PlaylistFolderPlaylistDestroyRequest;
use App\Http\Requests\API\PlaylistFolderPlaylistStoreRequest;
use App\Models\PlaylistFolder;
use App\Services\PlaylistFolderService;
use Illuminate\Support\Arr;

class PlaylistFolderPlaylistController extends Controller
{
    public function __construct(private PlaylistFolderService $service)
    {
    }

    public function store(PlaylistFolder $playlistFolder, PlaylistFolderPlaylistStoreRequest $request)
    {
        $this->authorize('own', $playlistFolder);

        $this->service->addPlaylistsToFolder($playlistFolder, Arr::wrap($request->playlists));

        return response()->noContent();
    }

    public function destroy(PlaylistFolder $playlistFolder, PlaylistFolderPlaylistDestroyRequest $request)
    {
        $this->authorize('own', $playlistFolder);

        $this->service->movePlaylistsToRootLevel(Arr::wrap($request->playlists));

        return response()->noContent();
    }
}

Function Calls

None

Variables

None

Stats

MD5 48a8ec6b2947afdac3694e3d99f2232f
Eval Count 0
Decode Time 105 ms