mirror of
https://github.com/firefly-iii/firefly-iii.git
synced 2025-09-19 02:45:58 +00:00
Moved find() method to new class.
This commit is contained in:
@@ -95,17 +95,16 @@ class AccountController extends Controller
|
||||
|
||||
/**
|
||||
* @param ARI $repository
|
||||
* @param AccountCrudInterface $crud
|
||||
* @param Account $account
|
||||
*
|
||||
* @return \Illuminate\Http\RedirectResponse|\Illuminate\Routing\Redirector
|
||||
*/
|
||||
public function destroy(ARI $repository, AccountCrudInterface $crud, Account $account)
|
||||
public function destroy(ARI $repository, Account $account)
|
||||
{
|
||||
$type = $account->accountType->type;
|
||||
$typeName = config('firefly.shortNamesByFullName.' . $type);
|
||||
$name = $account->name;
|
||||
$moveTo = $crud->find(intval(Input::get('move_account_before_delete')));
|
||||
$moveTo = $repository->find(intval(Input::get('move_account_before_delete')));
|
||||
|
||||
$repository->destroy($account, $moveTo);
|
||||
|
||||
|
Reference in New Issue
Block a user