dist/lib/api.js
function success(result, ignore) {
    return ((typeof result.error === 'undefined' &&
        typeof result.status === 'undefined' &&
        typeof result.success === 'undefined') ||
        (result.status && result.status === 'success') ||
        (result.success && result.success === true) ||
        (ignore && result.error && !ignore.test(result.error))) ? true : false;
}
function success(result, ignore) {
    return ((typeof result.error === 'undefined' &&
        typeof result.status === 'undefined' &&
        typeof result.success === 'undefined') ||
        (result.status && result.status === 'success') ||
        (result.success && result.success === true) ||
        (ignore && result.error && !ignore.test(result.error))) ? true : false;
}
function success ( result , ignore ) { return ( ( typeof result . error === 'undefined' && typeof result . status === 'undefined' && typeof result . success === 'undefined' ) || ( result . status && result . status === 'success' ) || ( result . success && result . success === true ) || ( ignore && result . error && ! ignore . test ( result . error ) ) ) ? true : false ; }
Check result data for success, allowing override to ignore some errors
Check result data for success allowing override to ignore some errors