Skip to content
This repository has been archived by the owner on Feb 6, 2024. It is now read-only.

Commit

Permalink
fix: currency amount is different in merchant-fulfillment
Browse files Browse the repository at this point in the history
  • Loading branch information
justinemmanuelmercado committed Jul 2, 2020
1 parent 927d10a commit 7df0580
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
1 change: 1 addition & 0 deletions src/sections/codec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import { Codec, number, optional, string } from 'purify-ts'
* Shared codecs
*/

// This is different from the CurrencyAmount used by merchant-fulfillment
export const CurrencyAmount = Codec.interface({
CurrencyCode: optional(string),
CurrencyAmount: optional(number),
Expand Down
6 changes: 5 additions & 1 deletion src/sections/merchant-fulfillment/codec.ts
Original file line number Diff line number Diff line change
@@ -1,13 +1,17 @@
import { boolean, Codec, enumeration, GetInterface, number, optional, string } from 'purify-ts'

import { ensureArray, ensureString, mwsDate } from '../../parsing'
import { CurrencyAmount } from '../codec'
import { PredefinedPackageDimensionsEnum } from './type'

export const TemporarilyUnavailableCarrier = Codec.interface({
CarrierName: string,
})

export const CurrencyAmount = Codec.interface({
CurrencyCode: string,
Amount: number,
})

export const RejectedShippingService = Codec.interface({
CarrierName: string,
ShippingServiceId: ensureString,
Expand Down

0 comments on commit 7df0580

Please sign in to comment.