Skip to content

[DEBT] Use asyncRemember #632

@SMEWebify

Description

@SMEWebify

need update laravel 12 befor

Before Update:

use Illuminate\Support\Facades\Cache;
// Caching a user
$user = Cache::remember('user_'.$id, 600, function () use ($id) {
    return User::find($id);
});

After Update:

use Illuminate\Support\Facades\Cache;
// Utilizing the new async caching API
$user = Cache::asyncRemember('user_'.$id, 600, function () use ($id) {
    return User::find($id);
});

Metadata

Metadata

Assignees

No one assigned

    Labels

    Reduce technical debtFacilitates long-term thinkingphpPull requests that update Php code

    Projects

    Status

    Backlog

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions