MCPcopy Create free account
hub / github.com/apache/cassandra-nodejs-driver / validateString

Function validateString

lib/client-options.js:308–314  ·  view source on GitHub ↗
(key)

Source from the content-addressed store, hash-verified

306
307function validateApplicationInfo(options) {
308 function validateString(key) {
309 const str = options[key];
310
311 if (str !== null && str !== undefined && typeof str !== 'string') {
312 throw new TypeError(`${key} should be a String`);
313 }
314 }
315
316 validateString('applicationName');
317 validateString('applicationVersion');

Callers 1

validateApplicationInfoFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected