accurator/commit
Saving user values as atoms instead of strings.
author | Chris Dijkshoorn |
---|---|
Mon Mar 9 16:34:50 2015 +0000 | |
committer | Chris Dijkshoorn |
Mon Mar 9 16:34:50 2015 +0000 | |
commit | 09a3415a6c4db967281f30b61d7f426de8e14c87 |
tree | 2e65dfa9b3670b582a49abef1cce25642086bf9f |
parent | 7813451e32939316c73abde06a9b104611affbd4 |
Diff style: patch stat
diff --git a/lib/accurator/accurator_user.pl b/lib/accurator/accurator_user.pl index 4713f47..b12f66f 100644 --- a/lib/accurator/accurator_user.pl +++ b/lib/accurator/accurator_user.pl @@ -90,7 +90,9 @@ save_user_info(Request) :- h1('Additional info successfuly saved.')). save_info_pairs(_User, []). -save_info_pairs(User, [Property-Value|Pairs]) :- +save_info_pairs(User, [PropertyString-ValueString|Pairs]) :- + atom_string(Property, PropertyString), + atom_string(Value, ValueString), InfoAtom =.. [Property, Value], set_user_property(User, InfoAtom), save_info_pairs(User, Pairs).