mirror of
https://github.com/node-ebics/node-ebics-client.git
synced 2026-10-07 12:49:14 +00:00
client and order optimization
This commit is contained in:
1 parent
187636019c
commit
945499290a
15 files changed
+259
-194
No files matched your search
@@ -3,10 +3,10 @@
|
||||
const H004Serializer = require('../orders/H004/serializer');
|
||||
|
||||
module.exports = {
|
||||
use(order) {
|
||||
use(order, client) {
|
||||
const { version } = order;
|
||||
|
||||
if (version.toUpperCase() === 'H004') return H004Serializer.use(order);
|
||||
if (version.toUpperCase() === 'H004') return H004Serializer.use(order, client);
|
||||
|
||||
throw Error('Error middleware/serializer.js: Invalid version number');
|
||||
},
|
||||
|
||||
Reference in new issue
Block a user