From f9fd0b636fd44d5e19af00a8584180a4d1f51041 Mon Sep 17 00:00:00 2001 From: bill bittner Date: Tue, 9 Jan 2018 13:21:15 -0800 Subject: [PATCH] updated model to add host data --- models/claim.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/models/claim.js b/models/claim.js index 4a8286dc..29e77e2c 100644 --- a/models/claim.js +++ b/models/claim.js @@ -1,6 +1,6 @@ const logger = require('winston'); const { returnShortId } = require('../helpers/sequelizeHelpers.js'); -const { claim } = require('../config/speechConfig.js'); +const { claim, site } = require('../config/speechConfig.js'); const { defaultThumbnail } = claim; function determineFileExtensionFromContentType (contentType) { @@ -31,6 +31,7 @@ function prepareClaimData (claim) { // logger.debug('preparing claim data based on resolved data:', claim); claim['thumbnail'] = determineThumbnail(claim.thumbnail, defaultThumbnail); claim['fileExt'] = determineFileExtensionFromContentType(claim.contentType); + claim['host'] = site.host; return claim; };