public function hasTranslation($language = null)
    {
        $language = $language ?: Yii::$app->language;

        foreach ($this->getModelTranslations() as $translation) {
            if ($translation->getAttribute($this->translationLanguageAttrName) === $language) {
                return true;
            }
        }

        return false;
    }