-
Notifications
You must be signed in to change notification settings - Fork 0
Conversation
and make NotebookAction conform to Hashable so we can do equality tests. This involved sending an error string, not an Error in the action, and marking a type Hashable.
@@ -211,6 +211,8 @@ struct NotebookDetailStackCursor: CursorProtocol { | |||
|
|||
static func tag(_ action: ViewModel.Action) -> NotebookModel.Action { | |||
switch action { | |||
case let .requestDeleteMemo(slashlink): | |||
return .requestDeleteMemo(slashlink) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add missing requestDelete interception. This fixes deletion in detail view.
...on profile
Not needed in this case because the view refreshes itself on appear.
Also make AppAction Hashable so we can compare it in tests.
...and make FeedAction Hashable for testing.
Note to self: the current information flow goes:
|
@bfollington this PR is ready to go, but an unrelated test I think that |
xcode/Subconscious/Shared/Components/Detail/UserProfileDetailView.swift
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A couple of formatting suggestions, but LGTM.
One thought: do we need Hashable
or just Equatable
for tests? I don't have strong feelings but I believe Hashable
extends Equatable
so it's a (slightly) stronger contract.
Fixes #941
QA: