-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* feat: introduce new order api method * feat: update payment transaction after sending payments * feat: refactored the api controllers * feat: added option for overriding controllers * chore: removed unused import * feat: provided the option for extending controllers * feat: call next() on error * fix: typo in webhook handler * feat: remove payment instrument from basket on error (#45) * chore: provide more examples about overriding endpoints * feat: fail order in case of payment unsuccessful * chore: extend example * chore: clean up unused functions * chore: clean up unused functions * feat: restructure
- Loading branch information
1 parent
ebf5d3f
commit e00f96b
Showing
26 changed files
with
492 additions
and
25,595 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
7 changes: 4 additions & 3 deletions
7
adyen/controllers/environment.js → adyen/api/controllers/environment.js
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,9 @@ | ||
async function getEnvironment(req, res) { | ||
res.json({ | ||
async function getEnvironment(req, res, next) { | ||
res.locals.response = { | ||
ADYEN_CLIENT_KEY: process.env.ADYEN_CLIENT_KEY, | ||
ADYEN_ENVIRONMENT: process.env.ADYEN_ENVIRONMENT | ||
}) | ||
} | ||
next() | ||
} | ||
|
||
export default getEnvironment |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.