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\Download; use App\Http\Controllers\Controller; use ..

Decoded Output download

<?php

namespace App\Http\Controllers\Download;

use App\Http\Controllers\Controller;
use App\Models\User;
use App\Repositories\InteractionRepository;
use App\Services\DownloadService;
use Illuminate\Contracts\Auth\Authenticatable;

class FavoritesController extends Controller
{
    /** @param User $user */
    public function __construct(
        private DownloadService $downloadService,
        private InteractionRepository $interactionRepository,
        private ?Authenticatable $user
    ) {
    }

    public function show()
    {
        $songs = $this->interactionRepository->getUserFavorites($this->user);

        return response()->download($this->downloadService->from($songs));
    }
}
 ?>

Did this file decode correctly?

Original Code

<?php

namespace App\Http\Controllers\Download;

use App\Http\Controllers\Controller;
use App\Models\User;
use App\Repositories\InteractionRepository;
use App\Services\DownloadService;
use Illuminate\Contracts\Auth\Authenticatable;

class FavoritesController extends Controller
{
    /** @param User $user */
    public function __construct(
        private DownloadService $downloadService,
        private InteractionRepository $interactionRepository,
        private ?Authenticatable $user
    ) {
    }

    public function show()
    {
        $songs = $this->interactionRepository->getUserFavorites($this->user);

        return response()->download($this->downloadService->from($songs));
    }
}

Function Calls

None

Variables

None

Stats

MD5 bded997ac0f8cb1dc5302c1525dcdc9c
Eval Count 0
Decode Time 91 ms