examples/HTML StarterKit/lib/durandal/js/activator.js
function(value) {
            if(system.isObject(value)) {
                value = value.can || false;
            }

            if(system.isString(value)) {
                return ko.utils.arrayIndexOf(this.affirmations, value.toLowerCase()) !== -1;
            }

            return value;
        }
function(value) {
            if(system.isObject(value)) {
                value = value.can || false;
            }

            if(system.isString(value)) {
                return ko.utils.arrayIndexOf(this.affirmations, value.toLowerCase()) !== -1;
            }

            return value;
        }
function ( value ) { if ( system . isObject ( value ) ) { value = value . can || false ; } if ( system . isString ( value ) ) { return ko . utils . arrayIndexOf ( this . affirmations , value . toLowerCase ( ) ) !== - 1 ; } return value ; }
Interprets the response of a `canActivate` or `canDeactivate` call using the known affirmative values in the `affirmations` array.
@method interpretResponse
@param {object} value
@return {boolean}
Interprets the response of a canActivate or canDeactivate call using the known affirmative values in the affirmations array .