mirror of
https://github.com/logsol/chuck.js.git
synced 2026-05-11 18:47:35 +00:00
21 lines
No EOL
345 B
JavaScript
21 lines
No EOL
345 B
JavaScript
define([
|
|
"Lib/Utilities/Exception"
|
|
],
|
|
|
|
function (Exception) {
|
|
|
|
"use strict";
|
|
|
|
var Assert = {};
|
|
|
|
Assert.number = function() {
|
|
for (var i = 0; i < arguments.length; i++) {
|
|
if(isNaN(parseFloat(arguments[i]))) {
|
|
throw new Exception("Assert: not a number ", JSON.stringify(arguments));
|
|
}
|
|
}
|
|
};
|
|
|
|
return Assert;
|
|
|
|
}); |