Page MenuHomePhabricator

[keyserver] Introduce `updateUserAvatar` updater and use in `updateUserAvatarResponder`
ClosedPublic

Authored by atul on Mar 22 2023, 11:19 PM.
Tags
None
Referenced Files
Unknown Object (File)
Mon, Nov 4, 11:19 PM
Unknown Object (File)
Mon, Nov 4, 11:19 PM
Unknown Object (File)
Mon, Nov 4, 11:18 PM
Unknown Object (File)
Mon, Nov 4, 11:18 PM
Unknown Object (File)
Mon, Nov 4, 11:18 PM
Unknown Object (File)
Thu, Oct 31, 3:50 PM
Unknown Object (File)
Wed, Oct 30, 7:22 AM
Unknown Object (File)
Oct 9 2024, 9:07 PM
Subscribers

Details

Summary

updateUserAvatar sets the avatar column of the users table for a given viewer with the contents of the UpdateUserAvatarRequest we receive from updateUserAvatarResponder... unless we receive { +type: 'remove' }, in which case we set the avatar column to null.

Test Plan

Use the following on native to send requests to keyserver:

16f6b9.png (534×1 px, 119 KB)

  1. Observe that avatar column is empty for user (atul-web):

fd53c5.png (232×1 px, 59 KB)

  1. Send request of type: 'emoji' and observe that column is populated:

36c12d.png (238×2 px, 70 KB)

  1. Send request of type: 'remove' and observe that column is empty again:

69044a.png (230×2 px, 64 KB)

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable