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

Remove transaction confirmation view endpoint #2276

Merged
merged 2 commits into from
Jan 27, 2025
Merged

Conversation

iamacook
Copy link
Member

Summary

Transaction confirmation views (/v1/chains/:chainId/safes/:safeAddress/views/transaction-confirmation) inherently mirrored transaction previews. As such, we previously deprecated it.

As the endpoint is no longer used, we can safely remove the implementation. This does that.

Changes

  • Remove transaction confirmation view: module, controller, service and entities
  • Simplify KilnDecoder methods that were dependant on the above
  • Update tests accordingly

@iamacook iamacook self-assigned this Jan 20, 2025
@iamacook iamacook requested a review from a team as a code owner January 20, 2025 17:00
@@ -181,7 +181,7 @@ export class NativeStakingMapper {
]);
this.validateDeployment(deployment);
const publicKeys = this.kilnNativeStakingHelper.splitPublicKeys(
this.kilnDecoder.decodeValidatorsExit(args.data)!.parameters[0].value,
this.kilnDecoder.decodeValidatorsExit(args.data)!,
Copy link
Contributor

Choose a reason for hiding this comment

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

This is not the concern of this PR but it's usually not a good practice to add ! to the variable when the function return type can be null even though the only case the return type can be null is when the data to decode is not validator exit

Copy link
Member Author

Choose a reason for hiding this comment

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

I agree, and it shouldn't be used. However, at this stage the data is that of requestValidatorsExit. We can update it in a follow up PR though.

@iamacook iamacook merged commit 31a1b6d into main Jan 27, 2025
20 checks passed
@iamacook iamacook deleted the remove-confirmation-view branch January 27, 2025 08:22
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