Example #1
0
    def get_object(self):
        user_settings = self.get_addon_settings()
        account_id = self.kwargs['account_id']

        account = ExternalAccount.load(account_id)
        if not (account and account in user_settings.external_accounts):
            raise NotFound('Requested addon unavailable')
        return account
def get_targets():
    return ExternalAccount.find(Q("provider", "eq", "zotero") | Q("provider", "eq", "mendeley"))
def get_targets():
    return ExternalAccount.find(Q('provider', 'eq', 'zotero') | Q('provider', 'eq', 'mendeley'))