Firebase signInWithEmailAndPassword()400()POST错误

时间:2016-07-06 21:55:49

标签: angularjs firebase firebase-authentication

我目前正在我的angularjs应用程序中实现新的firebase auth()并且每次调用

protected function isFileInUse()
{
    $owner = $this->getOwner();
    $dataObjectSubClasses = ClassInfo::subclassesFor('DataObject');
    $classesWithFileHasOne = [];
    foreach ($dataObjectSubClasses as $subClass) {
        $hasOnes = array_flip($subClass::create()->hasOne());
        if (array_key_exists($owner->class, $hasOnes)) {
            $classesWithFileHasOne[$subClass] = $hasOnes[$owner->class];
        }
    }

    $threshold = (Director::get_current_page()->class == 'AssetAdmin') ? 1 : 2;
    $uses = 0;
    foreach ($classesWithFileHasOne as $class => $relation) {
        $uses += count($class::get()->filter("{$relation}ID", $this->owner->ID));
        if ($uses >= $threshold) {
            return true;
        }
    }

    return false;
}

它会返回我的promise和error / user对象,但同时在控制台中抛出以下错误:

firebase.auth().signInWithEmailAndPassword(email, password)

似乎按预期工作但我不喜欢我的控制台中的错误:3

编辑:完全控制台错误(遗憾地缩小):

POST https://www.googleapis.com/identitytoolkit/v3/relyingparty/verifyPassword?key=[myKey] 400 () firebase.min.js:110

猜猜我必须联系firebase支持,对吧?

1 个答案:

答案 0 :(得分:4)

我可以确认@ bojeil的答案,错误是预期的行为。密码正确时不会发生!