Пример #1
0
	def create_user (self, user) :
		patterns.validate_user_name (user)
		patterns.validate_user_password (password)
		if user in self.users :
			raise Exception ((user, password))
		self.users.add (user)
		self.user_passwords[user] = None
		self.user_emails[user] = None
		self.user_data[user] = None
Пример #2
0
	def update_user_password (self, user, password) :
		patterns.validate_user_name (user)
		patterns.validate_user_password (password)
		if user not in self.users :
			raise Exception ()
		self.user_passwords[user] = password