Page MenuHomePhabricator

[lib] Allow calling link-disabling endpoint
ClosedPublic

Authored by tomek on May 22 2023, 6:29 AM.
Tags
None
Referenced Files
F3347548: D7907.diff
Fri, Nov 22, 12:34 PM
Unknown Object (File)
Wed, Nov 20, 5:37 PM
Unknown Object (File)
Mon, Nov 11, 7:04 PM
Unknown Object (File)
Mon, Nov 4, 4:49 PM
Unknown Object (File)
Sun, Nov 3, 3:27 AM
Unknown Object (File)
Mon, Oct 28, 8:57 AM
Unknown Object (File)
Sat, Oct 26, 12:14 AM
Unknown Object (File)
Thu, Oct 24, 1:44 AM
Subscribers

Details

Summary

The reducer deletes an entry in the store. In the future we will have to do more here, as not only public links can be disabled.

Depends on D7906

Test Plan

Confirm disabling a link and check if it was deleted, e.g. by verifying that disable link button disappears.

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

tomek requested review of this revision.May 22 2023, 6:47 AM

I think the differential name is not complete and confusing a bit

lib/reducers/invite-links-reducer.js
44

I would move currentPrimaryLink?.name === action.payload.name condition to if upper, and avoid modifying the state if it's falsy

This revision is now accepted and ready to land.May 22 2023, 10:44 AM
In D7907#234718, @kamil wrote:

I think the differential name is not complete and confusing a bit

It seems so... not sure what happened

tomek retitled this revision from [lib] Add reducer and endpoint calling code to [lib] Allow calling link-disabling endpoint.May 23 2023, 6:52 AM

Make reducer more efficient

This revision was automatically updated to reflect the committed changes.