Skip to content

Commit

Permalink
Fixed username trim removes information after dot (#1172)
Browse files Browse the repository at this point in the history
* Added assets information in get account API call

* 2.32.5

* Fixed username trim removes information after dot
  • Loading branch information
razvantomegea committed May 14, 2024
1 parent 70f4a2b commit 5178825
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
6 changes: 5 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,11 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]
## [[v2.32.4]](https://github.com/multiversx/mx-sdk-dapp/pull/1171)] - 2024-04-25

## [[v2.32.5]](https://github.com/multiversx/mx-sdk-dapp/pull/1173)] - 2024-03-14
- [Fixed username trim removes information after dot](https://github.com/multiversx/mx-sdk-dapp/pull/1172)

## [[v2.32.4]](https://github.com/multiversx/mx-sdk-dapp/pull/1171)] - 2024-05-13
- [Fixed webview custom message method](https://github.com/multiversx/mx-sdk-dapp/pull/1170)

## [[v2.32.3]](https://github.com/multiversx/mx-sdk-dapp/pull/1169)] - 2024-04-25
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@multiversx/sdk-dapp",
"version": "2.32.4",
"version": "2.32.5",
"description": "A library to hold the main logic for a dapp on the MultiversX blockchain",
"author": "MultiversX",
"license": "GPL-3.0-or-later",
Expand Down
4 changes: 2 additions & 2 deletions src/hooks/account/helpers/trimUsernameDomain.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,8 @@ export const trimUsernameDomain = (username?: string) => {
return;
}

const dotExists = username.lastIndexOf('.') > 0;
const trimmedPartBeforeLastDot = dotExists
const elrondSuffixExists = username.lastIndexOf('.elrond') > 0;
const trimmedPartBeforeLastDot = elrondSuffixExists
? username.substring(0, username.lastIndexOf('.'))
: username;

Expand Down

0 comments on commit 5178825

Please sign in to comment.