Created
March 17, 2020 04:16
-
-
Save phanviet/9b5234f849411df5897731f285115aeb to your computer and use it in GitHub Desktop.
This file contains hidden or 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
export { TemplateSentError, Unauthorized, ValidateError } from './errors'; | |
import { generalUtils } from './general-utils'; | |
import { dynamodbUtils } from './dynamodb-utils'; | |
import { listUtils } from './list-utils'; | |
import { mapUtils } from './map-utils'; | |
import { rdsUtils } from './rds-utils'; | |
import { transformUtils } from './transform'; | |
import { time } from './time'; | |
import { GraphQLResolveInfo } from 'graphql'; | |
export function create(errors = [], now: Date = new Date(), info: GraphQLResolveInfo) { | |
return { | |
...generalUtils, | |
dynamodb: dynamodbUtils, | |
list: listUtils, | |
map: mapUtils, | |
rds: rdsUtils, | |
transform: transformUtils, | |
now, | |
errors, | |
info, | |
time: time(), | |
}; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment