prvi
This commit is contained in:
17
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/create_error.js
vendored
Normal file
17
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/create_error.js
vendored
Normal file
@@ -0,0 +1,17 @@
|
||||
|
||||
|
||||
var createError = function( code, attributes ) {
|
||||
var error, message;
|
||||
|
||||
message = code + ( attributes && JSON ? ": " + JSON.stringify( attributes ) : "" );
|
||||
error = new Error( message );
|
||||
error.code = code;
|
||||
|
||||
// extend( error, attributes );
|
||||
arrayForEach( objectKeys( attributes ), function( attribute ) {
|
||||
error[ attribute ] = attributes[ attribute ];
|
||||
});
|
||||
|
||||
return error;
|
||||
};
|
||||
|
||||
8
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/validate.js
vendored
Normal file
8
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/validate.js
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
|
||||
|
||||
var validate = function( code, check, attributes ) {
|
||||
if ( !check ) {
|
||||
throw createError( code, attributes );
|
||||
}
|
||||
};
|
||||
|
||||
8
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/validate/presence.js
vendored
Normal file
8
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/validate/presence.js
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
|
||||
|
||||
var validatePresence = function( value, name ) {
|
||||
validate( "E_MISSING_PARAMETER", typeof value !== "undefined", {
|
||||
name: name
|
||||
});
|
||||
};
|
||||
|
||||
10
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/validate/type.js
vendored
Normal file
10
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/validate/type.js
vendored
Normal file
@@ -0,0 +1,10 @@
|
||||
|
||||
|
||||
var validateType = function( value, name, check, expected ) {
|
||||
validate( "E_INVALID_PAR_TYPE", check, {
|
||||
expected: expected,
|
||||
name: name,
|
||||
value: value
|
||||
});
|
||||
};
|
||||
|
||||
6
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/validate/type/function.js
vendored
Normal file
6
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/validate/type/function.js
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
|
||||
|
||||
var validateTypeFunction = function( value, name ) {
|
||||
validateType( value, name, typeof value === "undefined" || typeof value === "function", "Function" );
|
||||
};
|
||||
|
||||
6
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/validate/type/path.js
vendored
Normal file
6
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/validate/type/path.js
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
|
||||
|
||||
var validateTypePath = function( value, name ) {
|
||||
validateType( value, name, typeof value === "string" || arrayIsArray( value ), "String or Array" );
|
||||
};
|
||||
|
||||
6
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/validate/type/plain_object.js
vendored
Normal file
6
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/validate/type/plain_object.js
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
|
||||
|
||||
var validateTypePlainObject = function( value, name ) {
|
||||
validateType( value, name, typeof value === "undefined" || isPlainObject( value ), "Plain Object" );
|
||||
};
|
||||
|
||||
6
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/validate/type/string.js
vendored
Normal file
6
EveryThing/wwwroot/vendor/libs/cldrjs/dist/.build/common/validate/type/string.js
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
|
||||
|
||||
var validateTypeString = function( value, name ) {
|
||||
validateType( value, name, typeof value === "string", "a string" );
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user