From b2a86b06d37acd609eeb8ef7d5699d3ba0af55d4 Mon Sep 17 00:00:00 2001 From: Guilherme Macedo Date: Fri, 23 Nov 2018 22:00:57 -0200 Subject: [PATCH] Fixed for issue 1150 Fixed issue https://github.com/Netflix/security_monkey/issues/1150 --- security_monkey/views/item.py | 2 -- 1 file changed, 2 deletions(-) diff --git a/security_monkey/views/item.py b/security_monkey/views/item.py index 5588e6ccc..fe2703489 100644 --- a/security_monkey/views/item.py +++ b/security_monkey/views/item.py @@ -229,7 +229,6 @@ def get(self): query = query.filter(Account.name.in_(accounts)) if 'accounttypes' in args: accounttypes = args['accounttypes'].split(',') - query = query.join((Account, Account.id == Item.account_id)) query = query.join((AccountType, AccountType.id == Account.account_type_id)) query = query.filter(AccountType.name.in_(accounttypes)) if 'technologies' in args: @@ -248,7 +247,6 @@ def get(self): if 'active' in args: active = args['active'].lower() == "true" query = query.filter(ItemRevision.active == active) - query = query.join((Account, Account.id == Item.account_id)) query = query.filter(Account.active == True) if 'searchconfig' in args: searchconfig = args['searchconfig']