Move plugin manager call to end

This commit is contained in:
johannes.kaufmann
2019-12-02 15:58:01 +01:00
parent 6c00595073
commit 1af3b71585

View File

@@ -25,8 +25,6 @@ def ensure_user(username):
# User doesn't exist, time to create! # User doesn't exist, time to create!
pass pass
pm = get_plugin_manager()
subprocess.check_call([ subprocess.check_call([
'useradd', 'useradd',
'--create-home', '--create-home',
@@ -39,6 +37,7 @@ def ensure_user(username):
expanduser('~{username}'.format(username=username)) expanduser('~{username}'.format(username=username))
]) ])
pm = get_plugin_manager()
pm.hook.tljh_new_user_create(username=username) pm.hook.tljh_new_user_create(username=username)