mirror of
https://github.com/EGroupware/egroupware.git
synced 2024-11-08 00:54:15 +01:00
Fix fatal error when deleting favorites
This commit is contained in:
parent
f3aca6f1d7
commit
8b30732aa0
@ -240,9 +240,9 @@ class Favorites
|
|||||||
$pref = $prefs->save_repository(false,$type);
|
$pref = $prefs->save_repository(false,$type);
|
||||||
|
|
||||||
// Update preferences client side, or it could disappear
|
// Update preferences client side, or it could disappear
|
||||||
Api\Json\Responseget()->call('egw.set_preferences', (array)$pref[$app], $app);
|
Api\Json\Response::get()->call('egw.set_preferences', (array)$pref[$app], $app);
|
||||||
|
|
||||||
Api\Json\Responseget()->data(isset($result[$app][$pref_name]));
|
Api\Json\Response::get()->data(isset($result[$app][$pref_name]));
|
||||||
return isset($result[$app][$pref_name]);
|
return isset($result[$app][$pref_name]);
|
||||||
}
|
}
|
||||||
else if ($action == "delete")
|
else if ($action == "delete")
|
||||||
@ -251,9 +251,9 @@ class Favorites
|
|||||||
$pref = $prefs->save_repository(false,$type);
|
$pref = $prefs->save_repository(false,$type);
|
||||||
|
|
||||||
// Update preferences client side, or it could come back
|
// Update preferences client side, or it could come back
|
||||||
Api\Json\Responseget()->call('egw.set_preferences', (array)$pref[$app], $app);
|
Api\Json\Response::get()->call('egw.set_preferences', (array)$pref[$app], $app);
|
||||||
|
|
||||||
Api\Json\Responseget()->data(!isset($result[$app][$pref_name]));
|
Api\Json\Response::get()->data(!isset($result[$app][$pref_name]));
|
||||||
return !isset($result[$app][$pref_name]);
|
return !isset($result[$app][$pref_name]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user