Commit 18d84b91 authored by Michal Čihař's avatar Michal Čihař

Validate only if project is set

parent f48b360e
...@@ -754,7 +754,13 @@ class SubProject(models.Model): ...@@ -754,7 +754,13 @@ class SubProject(models.Model):
Validator fetches repository and tries to find translation files. Validator fetches repository and tries to find translation files.
Then it checks them for validity. Then it checks them for validity.
''' '''
# Skip validation if we don't have valid project
if self.project_id is None:
return
# Validate git repo
self.sync_git_repo(True) self.sync_git_repo(True)
try: try:
matches = self.get_mask_matches() matches = self.get_mask_matches()
if len(matches) == 0: if len(matches) == 0:
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment