Authored by 陈峰

commit

... ... @@ -32,7 +32,7 @@ module.exports = {
app: 'h5',
appVersion: '6.6.0', // 调用api的版本
appName: 'yohoapp-node',
port: 6003,
port: 6001,
siteUrl: '//m.yohobuy.com',
assetUrl: '//localhost:5001/yohoapp-node/',
testCode: 'yoho4946abcdef#$%&!@',
... ...
... ... @@ -21,6 +21,11 @@ const assetType = (value, type) => {
if (!valid && t === 'object') {
valid = value instanceof type;
}
if (!valid && expectedType.toLowerCase() === 'number') {
const parseNumber = parseInt(value, 10);
valid = parseNumber || parseNumber === 0;
}
} else if (expectedType === 'Object') {
valid = value.toString() === '[object Object]';
} else if (expectedType === 'Array') {
... ...