MCPcopy Create free account
hub / github.com/scottrogowski/code2flow / getSetRelativeTimeThreshold

Function getSetRelativeTimeThreshold

tests/test_code/js/moment/moment.js:5448–5460  ·  view source on GitHub ↗
(threshold, limit)

Source from the content-addressed store, hash-verified

5446
5447 // This function allows you to set a threshold for relative time strings
5448 function getSetRelativeTimeThreshold(threshold, limit) {
5449 if (thresholds[threshold] === undefined) {
5450 return false;
5451 }
5452 if (limit === undefined) {
5453 return thresholds[threshold];
5454 }
5455 thresholds[threshold] = limit;
5456 if (threshold === 's') {
5457 thresholds.ss = limit - 1;
5458 }
5459 return true;
5460 }
5461
5462 function humanize(argWithSuffix, argThresholds) {
5463 if (!this.isValid()) {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected