Example #1
0
 .then(function (cred) {
     if (is_oauth) {
         return provider.oAuthRefreshAccessToken(cred)
             .then(function (new_cred) {
                 return utils.saveCredentials(new_cred)
                     .then(function () {
                         return FileFog.client(Name, new_cred,FilefogOptions)
                     })
             })
     }
     else {
         return FileFog.client(Name, cred,FilefogOptions);
     }
 })
Example #2
0
 .then(function () {
     return FileFog.client(Name, new_cred,FilefogOptions)
 })