mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-02-25 18:45:27 -06:00
Fix #1003
This commit is contained in:
parent
6a88064548
commit
8f6ea6a73f
@ -84,12 +84,13 @@ class Preferences
|
||||
*/
|
||||
public function get($name, $default = null)
|
||||
{
|
||||
/** @var User $user */
|
||||
$user = auth()->user();
|
||||
if (null === $user) {
|
||||
return $default;
|
||||
}
|
||||
|
||||
return $this->getForUser(auth()->user(), $name, $default);
|
||||
return $this->getForUser($user, $name, $default);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -126,6 +127,7 @@ class Preferences
|
||||
{
|
||||
$fullName = sprintf('preference%s%s', $user->id, $name);
|
||||
if (Cache::has($fullName)) {
|
||||
|
||||
return Cache::get($fullName);
|
||||
}
|
||||
|
||||
|
@ -129,7 +129,7 @@
|
||||
<div class="checkbox">
|
||||
<label>
|
||||
<input type="checkbox" name="showDepositsFrontpage[]" value="{{ showDeps }}"
|
||||
{% if showDepositsFrontpage %}
|
||||
{% if showDeps %}
|
||||
checked
|
||||
{% endif %}
|
||||
> {{ 'pref_home_do_show_deposits'|_ }}
|
||||
|
Loading…
Reference in New Issue
Block a user