Renaming function get_config_or_default to get_or_generate_config

remotes/origin/enhancement/email-actions
Alejandro Alonso 2014-11-05 09:35:59 +01:00 committed by David Barragán Merino
parent 88d11aba85
commit 63cf345ff0
2 changed files with 2 additions and 2 deletions

View File

@ -342,7 +342,7 @@ CHANGE_NOTIFICATIONS_MIN_INTERVAL = 0 #seconds
# List of functions called for filling correctly the ProjectModulesConfig associated to a project # List of functions called for filling correctly the ProjectModulesConfig associated to a project
# This functions should receive a Project parameter and return a dict with the desired configuration # This functions should receive a Project parameter and return a dict with the desired configuration
PROJECT_MODULES_CONFIGURATORS = { PROJECT_MODULES_CONFIGURATORS = {
"github": "taiga.github_hook.services.get_config_or_default", "github": "taiga.github_hook.services.get_or_generate_config",
} }

View File

@ -22,7 +22,7 @@ from taiga.users.models import User
from taiga.base.utils.urls import get_absolute_url from taiga.base.utils.urls import get_absolute_url
def get_config_or_default(project): def get_or_generate_config(project):
config = project.modules_config.config config = project.modules_config.config
if config and "github" in config: if config and "github" in config:
g_config = project.modules_config.config["github"] g_config = project.modules_config.config["github"]