@ecency/wallets 1.5.21 → 1.5.23

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3642,7 +3642,7 @@ function getTokenOperationsQueryOptions(token, username, isForOwner = false, cur
3642
3642
  queryFn: async () => {
3643
3643
  const queryClient = sdk.getQueryClient();
3644
3644
  const normalizedToken = token.toUpperCase();
3645
- if (!username) {
3645
+ if (!username || !isForOwner) {
3646
3646
  return [];
3647
3647
  }
3648
3648
  try {
@@ -3778,12 +3778,13 @@ var PATHS = {
3778
3778
  ["APT" /* APT */]: "m/44'/637'/0'/0'/0'"
3779
3779
  // Aptos (BIP44)
3780
3780
  };
3781
- function useWalletCreate(username, currency) {
3782
- const { data: mnemonic } = useSeedPhrase(username);
3781
+ function useWalletCreate(username, currency, importedSeed) {
3782
+ const { data: generatedMnemonic } = useSeedPhrase(username);
3783
3783
  const queryClient = reactQuery.useQueryClient();
3784
3784
  const createWallet = reactQuery.useMutation({
3785
3785
  mutationKey: ["ecency-wallets", "create-wallet", username, currency],
3786
3786
  mutationFn: async () => {
3787
+ const mnemonic = importedSeed || generatedMnemonic;
3787
3788
  if (!mnemonic) {
3788
3789
  throw new Error("[Ecency][Wallets] - No seed to create a wallet");
3789
3790
  }