MCPcopy Index your code
hub / github.com/Macuyiko/minecraft-python / checkOption

Function checkOption

ServerEditorWeb/ace/worker-javascript.js:2373–2388  ·  view source on GitHub ↗
(name, t)

Source from the content-addressed store, hash-verified

2371 emitter = new events.EventEmitter();
2372
2373 function checkOption(name, t) {
2374 name = name.trim();
2375
2376 if (/^[+-]W\d{3}$/g.test(name)) {
2377 return true;
2378 }
2379
2380 if (options.validNames.indexOf(name) === -1) {
2381 if (t.type !== "jslint" && !_.has(options.removed, name)) {
2382 error("E001", t, name);
2383 return false;
2384 }
2385 }
2386
2387 return true;
2388 }
2389
2390 function isString(obj) {
2391 return Object.prototype.toString.call(obj) === "[object String]";

Callers 2

doOptionFunction · 0.85
itselfFunction · 0.85

Calls 1

errorFunction · 0.70

Tested by

no test coverage detected