creer_compte_wiki: creer_compte renvoie un tuple
This commit is contained in:
parent
9788cadfec
commit
937aab00af
1 changed files with 7 additions and 6 deletions
|
@ -1,4 +1,4 @@
|
|||
#! /usr/bin/env python
|
||||
#!/bin/bash /usr/scripts/python.sh
|
||||
# -*- coding: utf-8 -*-
|
||||
|
||||
# Script de création de compte sur le wiki
|
||||
|
@ -13,9 +13,10 @@ from email.MIMEText import MIMEText
|
|||
from email.MIMEMultipart import MIMEMultipart
|
||||
from email.Encoders import encode_7or8bit
|
||||
|
||||
sys.path.append("/usr/scripts/gestion")
|
||||
from affich_tools import coul, prompt, cprint
|
||||
from user_tests import getuser
|
||||
if '/usr/scripts' not in sys.path:
|
||||
sys.path.append("/usr/scripts")
|
||||
from gestion.affich_tools import coul, prompt, cprint
|
||||
from gestion.user_tests import getuser
|
||||
|
||||
bugmail = ["root@crans.org"]
|
||||
bugreport = u"""
|
||||
|
@ -83,8 +84,8 @@ correctement configuré (en %s).""" % (locale.getdefaultlocale()[1])
|
|||
msg.attach(txt)
|
||||
msg.attach(html)
|
||||
send(msg, user)
|
||||
return coul(u"Erreur inconnue\n", "rouge") + \
|
||||
u"Un rapport de bug a été automatiquement envoyé. Réessayez plus tard."
|
||||
return (u"Erreur inconnue\nUn rapport de bug a été envoyé."
|
||||
u"Réessayez plus tard."), False
|
||||
|
||||
if __name__ == '__main__':
|
||||
try:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue