Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(app): fix pinned protocol deletion issue #13553

Merged
merged 1 commit into from
Sep 14, 2023

Conversation

koji
Copy link
Contributor

@koji koji commented Sep 14, 2023

Overview

The issue was that the right protocolId wasn't set correctly when tapping the delete button.

delete_protocol.mov

fix RQA-1588

Test Plan

  1. Send a couple of protocols to a dev kit or a Flex
  2. Pin a protocol
  3. delete the pinned protocol -> deletion is done correctly
  4. delete a protocol (not pinned) -> deletion is done correctly

Changelog

  • update components that are related to delete protocol in ProtocolDashboard
  • update the tests that are related to the above components

Review requests

Risk assessment

low

The issue was that the right protocolId wasn't set correctly when tapping the delete button
@koji koji requested a review from a team September 14, 2023 17:17
@koji koji marked this pull request as ready for review September 14, 2023 17:17
@koji koji requested a review from a team as a code owner September 14, 2023 17:17
@koji koji requested review from b-cooper and removed request for a team and b-cooper September 14, 2023 17:17
@codecov
Copy link

codecov bot commented Sep 14, 2023

Codecov Report

Merging #13553 (5dc392c) into chore_release-7.0.0 (552cd65) will increase coverage by 0.00%.
The diff coverage is 57.14%.

Additional details and impacted files

Impacted file tree graph

@@                 Coverage Diff                  @@
##           chore_release-7.0.0   #13553   +/-   ##
====================================================
  Coverage                71.31%   71.31%           
====================================================
  Files                     2419     2419           
  Lines                    68080    68082    +2     
  Branches                  7908     7908           
====================================================
+ Hits                     48550    48552    +2     
+ Misses                   17679    17678    -1     
- Partials                  1851     1852    +1     
Flag Coverage Δ
app 68.93% <57.14%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files Changed Coverage Δ
...pages/ProtocolDashboard/PinnedProtocolCarousel.tsx 8.33% <0.00%> (ø)
app/src/pages/ProtocolDashboard/index.tsx 0.00% <0.00%> (ø)
...tocolDashboard/DeleteProtocolConfirmationModal.tsx 78.57% <50.00%> (-2.20%) ⬇️
app/src/pages/ProtocolDashboard/LongPressModal.tsx 54.05% <100.00%> (+1.27%) ⬆️
app/src/pages/ProtocolDashboard/PinnedProtocol.tsx 83.33% <100.00%> (ø)
app/src/pages/ProtocolDashboard/ProtocolCard.tsx 62.00% <100.00%> (ø)

Copy link
Collaborator

@jerader jerader left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm 🐳

@@ -39,15 +39,15 @@ export function ProtocolCard(props: {
protocol: ProtocolResource
longPress: React.Dispatch<React.SetStateAction<boolean>>
setShowDeleteConfirmationModal: (showDeleteConfirmationModal: boolean) => void
setTargetProtocol: (targetProtocol: ProtocolResource) => void
setTargetProtocolId: (targetProtocolId: string) => void
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yup this seems a lot better to grab the protocolId rather than the whole protocol resource

@koji koji merged commit 03d328b into chore_release-7.0.0 Sep 14, 2023
@koji koji deleted the fix_delete-protocol-issue-in-odd branch September 14, 2023 18:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants