This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// for multiple requests | |
let isRefreshing = false; | |
let failedQueue = []; | |
const processQueue = (error, token = null) => { | |
failedQueue.forEach(prom => { | |
if (error) { | |
prom.reject(error); | |
} else { | |
prom.resolve(token); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<templateSet group="AndroidLogKotlin"> | |
<template name="logd" value="android.util.Log.d("$CLASS_NAME$", "$METHOD_NAME$ (line $LINE$): $MESSAGE$")$END$" description="Log.d statement" toReformat="false" toShortenFQNames="true"> | |
<variable name="CLASS_NAME" expression="groovyScript("if(_1.length() > 23) { return _1.substring(0, 23)} else { return _1}", kotlinClassName())" defaultValue="" alwaysStopAt="true" /> | |
<variable name="METHOD_NAME" expression="kotlinFunctionName()" defaultValue="" alwaysStopAt="false" /> | |
<variable name="LINE" expression="lineNumber()" defaultValue="" alwaysStopAt="false" /> | |
<variable name="MESSAGE" expression="" defaultValue="" alwaysStopAt="true" /> | |
<context> | |
<option name="KOTLIN_STATEMENT" value="true" /> | |
</context> | |
</template> |
NewerOlder