Skip to content

Commit

Permalink
Move request validation after it determines if the chain is valid
Browse files Browse the repository at this point in the history
  • Loading branch information
aaroncox committed May 26, 2023
1 parent 302891f commit 34704ee
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -125,9 +125,6 @@ export class TransactPluginResourceProvider extends AbstractTransactPlugin {
t = context.ui.getTranslate(this.id)
}

// Validate that this request is valid for the resource provider
this.validateRequest(request, context)

// Determine appropriate URL for this request
const endpoint = this.getEndpoint(context.chain)

Expand All @@ -138,6 +135,9 @@ export class TransactPluginResourceProvider extends AbstractTransactPlugin {
}
}

// Validate that this request is valid for the resource provider
this.validateRequest(request, context)

// Assemble the request to the resource provider.
const url = `${endpoint}/v1/resource_provider/request_transaction`

Expand Down

0 comments on commit 34704ee

Please sign in to comment.