diff --git a/backend/grant/ccr/views.py b/backend/grant/ccr/views.py index 4b6fa784..28c1077a 100644 --- a/backend/grant/ccr/views.py +++ b/backend/grant/ccr/views.py @@ -48,6 +48,7 @@ def make_ccr_draft(): def get_ccr_drafts(): ccrs = ( CCR.query + .filter_by(user_id=g.current_user.id) .filter(or_( CCR.status == CCRStatus.DRAFT, CCR.status == CCRStatus.REJECTED, diff --git a/backend/grant/utils/requests.py b/backend/grant/utils/requests.py index cd63b52d..06c1cd82 100644 --- a/backend/grant/utils/requests.py +++ b/backend/grant/utils/requests.py @@ -30,6 +30,9 @@ def blockchain_get(path, params=None): def validate_blockchain_get(path, params=None): + if path == '/validate/address' and params and params['address'] and params['address'][0] == 't': + raise ValidationException('T addresses are not allowed') + try: res = blockchain_get(path, params) except Exception: diff --git a/frontend/client/components/Settings/Account/RefundAddress.tsx b/frontend/client/components/Settings/Account/RefundAddress.tsx index 070ca895..54c0ab77 100644 --- a/frontend/client/components/Settings/Account/RefundAddress.tsx +++ b/frontend/client/components/Settings/Account/RefundAddress.tsx @@ -65,7 +65,7 @@ export default class RefundAddress extends React.Component { diff --git a/frontend/client/utils/validators.ts b/frontend/client/utils/validators.ts index 348b32dd..9ed97bbe 100644 --- a/frontend/client/utils/validators.ts +++ b/frontend/client/utils/validators.ts @@ -78,5 +78,5 @@ export function isValidSaplingAddress(address: string): boolean { } export function isValidAddress(a: string): boolean { - return isValidTAddress(a) || isValidSproutAddress(a) || isValidSaplingAddress(a); + return isValidSproutAddress(a) || isValidSaplingAddress(a); }