diff options
| author | 2023-04-16 07:43:41 +0200 | |
|---|---|---|
| committer | 2023-04-16 07:43:41 +0200 | |
| commit | 0240c871f306f03d105d2ce9ca101932c014fcbd (patch) | |
| tree | db9e1c8d77a60104bae61e155679761cbed01530 /mastoapi.c | |
| parent | Temporary fix to this account show error. (diff) | |
| download | snac2-0240c871f306f03d105d2ce9ca101932c014fcbd.tar.gz snac2-0240c871f306f03d105d2ce9ca101932c014fcbd.tar.xz snac2-0240c871f306f03d105d2ce9ca101932c014fcbd.zip | |
New function user_open_by_md5().
Diffstat (limited to 'mastoapi.c')
| -rw-r--r-- | mastoapi.c | 6 |
1 files changed, 1 insertions, 5 deletions
| @@ -722,12 +722,8 @@ int mastoapi_get_handler(const xs_dict *req, const char *q_path, | |||
| 722 | xs *out = NULL; | 722 | xs *out = NULL; |
| 723 | xs *actor = NULL; | 723 | xs *actor = NULL; |
| 724 | 724 | ||
| 725 | /* if uid it's the md5 of this actor, transform into a real uid */ | ||
| 726 | if (strcmp(uid, snac1.md5) == 0) | ||
| 727 | uid = xs_dict_get(snac1.config, "uid"); | ||
| 728 | |||
| 729 | /* is it a local user? */ | 725 | /* is it a local user? */ |
| 730 | if (user_open(&snac2, uid)) { | 726 | if (user_open(&snac2, uid) || user_open_by_md5(&snac2, uid)) { |
| 731 | if (opt == NULL) { | 727 | if (opt == NULL) { |
| 732 | /* account information */ | 728 | /* account information */ |
| 733 | actor = msg_actor(&snac2); | 729 | actor = msg_actor(&snac2); |