Fixes auth-user-add.
parent
0265383d05
commit
25361bf7aa
|
@ -448,7 +448,7 @@ module AuthD
|
|||
def add_user(login : String, password : String,
|
||||
email : String?,
|
||||
phone : String?,
|
||||
profile : JSON::Any?) : ::AuthD::User::Public | Exception
|
||||
profile : Hash(String, JSON::Any)?) : ::AuthD::User::Public | Exception
|
||||
|
||||
send Request::AddUser.new @key, login, password, email, phone, profile
|
||||
|
||||
|
@ -513,7 +513,7 @@ module AuthD
|
|||
password : String,
|
||||
email : String?,
|
||||
phone : String?,
|
||||
profile : JSON::Any?) : ::AuthD::User::Public?
|
||||
profile : Hash(String, JSON::Any)?) : ::AuthD::User::Public?
|
||||
|
||||
send Request::Register.new login, password, email, phone, profile
|
||||
response = Response.from_ipc read
|
||||
|
|
|
@ -53,7 +53,7 @@ login = cli_login.not_nil! # not_nil!? O RLY?
|
|||
|
||||
profile = profile_file.try do |file|
|
||||
begin
|
||||
JSON.parse File.read file
|
||||
JSON.parse(File.read file).as_h
|
||||
rescue e
|
||||
STDERR.puts e.message
|
||||
exit 1
|
||||
|
|
Loading…
Reference in New Issue