diff --git a/brewman/models/auth.py b/brewman/models/auth.py index 97e37958..73f95f9a 100644 --- a/brewman/models/auth.py +++ b/brewman/models/auth.py @@ -108,6 +108,8 @@ class User(Base): @classmethod def by_name(cls, name): + if not name: + return None return DBSession.query(cls).filter(cls.name.ilike(name)).first() @classmethod diff --git a/brewman/static/scripts/account.js b/brewman/static/scripts/account.js index 57b47f9f..65f8f98b 100644 --- a/brewman/static/scripts/account.js +++ b/brewman/static/scripts/account.js @@ -59,7 +59,6 @@ var AccountCtrl = ['$scope', '$location', '$modal', 'account', 'account_types', AccountCtrl.resolve = { account: ['$route', 'Account', function ($route, Account) { var id = $route.current.params.id; - return Account.get({id: id}).$promise; }], account_types: ['AccountType', function (AccountType) { diff --git a/brewman/static/template/modal/confirm.html b/brewman/static/template/modal/confirm.html index c644e15a..b7a09234 100644 --- a/brewman/static/template/modal/confirm.html +++ b/brewman/static/template/modal/confirm.html @@ -1,13 +1,17 @@ -