diff --git a/sdk/apps/modal-example/package.json b/sdk/apps/modal-example/package.json index 2f7293bf..e50af219 100644 --- a/sdk/apps/modal-example/package.json +++ b/sdk/apps/modal-example/package.json @@ -22,7 +22,7 @@ "@nightlylabs/nightly-connect-polkadot": "0.0.16", "@nightlylabs/nightly-connect-solana": "0.0.29", "@nightlylabs/nightly-connect-sui": "0.1.0", - "@nightlylabs/wallet-selector-aptos": "0.1.8", + "@nightlylabs/wallet-selector-aptos": "0.1.9", "@nightlylabs/wallet-selector-base": "^0.4.1", "@nightlylabs/wallet-selector-polkadot": "0.2.7", "@nightlylabs/wallet-selector-solana": "0.3.6", diff --git a/sdk/packages/selector-aptos/package.json b/sdk/packages/selector-aptos/package.json index 741eb36a..b5b47a32 100644 --- a/sdk/packages/selector-aptos/package.json +++ b/sdk/packages/selector-aptos/package.json @@ -1,6 +1,6 @@ { "name": "@nightlylabs/wallet-selector-aptos", - "version": "0.1.8", + "version": "0.1.9", "description": "", "type": "module", "exports": { diff --git a/sdk/packages/selector-aptos/src/adapter.ts b/sdk/packages/selector-aptos/src/adapter.ts index c5910d39..3cec7332 100644 --- a/sdk/packages/selector-aptos/src/adapter.ts +++ b/sdk/packages/selector-aptos/src/adapter.ts @@ -329,7 +329,11 @@ export class NightlyConnectAptosAdapter extends EventEmitter throw new Error('Not connected') } if (this._connectionType === ConnectionType.Nightly) { - return await this._app!.changeNetwork(networkInfo) + const response = await this._app!.changeNetwork(networkInfo) + if (response.status === UserResponseStatus.APPROVED) { + this._networkInfo = networkInfo + } + return response } if (this._connectionType === ConnectionType.WalletStandard) { return await this._innerStandardAdapter!.features['aptos:changeNetwork']!.changeNetwork(