UNPKG

@hipay/hipay-enterprise-sdk-nodejs

Version:

The HiPay Enterprise SDK for NodeJS is a library for developers who want to integrate HiPay Enterprise payment methods to any NodeJS platform.

20 lines (15 loc) 754 B
'use strict'; const AbstractMapper = require('../../Mapper/AbstractMapper'); const PaymentMethodMapper = require('./PaymentMethodMapper'); const PaymentProduct = require('../PaymentProduct'); class PaymentProductMapper extends AbstractMapper { mapResponseToModel() { const values = { paymentMethod: typeof this.source.paymentMethod !== 'undefined' ? new PaymentMethodMapper(this.source.paymentMethod).mappedObject : null, name: typeof this.source.name !== 'undefined' ? this.source.name : null, description: typeof this.source.description !== 'undefined' ? this.source.description : null }; this._modelObject = new PaymentProduct(values); } } module.exports = PaymentProductMapper;