Skip to content

Commit 18ab161

Browse files
committed
feat: 增加 enableIpLocator 参数控制
1 parent ce828de commit 18ab161

File tree

1 file changed

+2
-2
lines changed
  • src/BootstrapBlazor/wwwroot/modules

1 file changed

+2
-2
lines changed

src/BootstrapBlazor/wwwroot/modules/hub.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import Data from "./data.js"
33
import EventHandler from "./event-handler.js";
44

55
export async function init(id, options) {
6-
const { invoke, method, interval = 3000, url, connectionId } = options;
6+
const { invoke, method, interval = 3000, url, connectionId, enableIpLocator } = options;
77
const elKey = 'bb_hub_el_id';
88
if (localStorage.getItem(elKey) === null) {
99
localStorage.setItem(elKey, id);
@@ -34,7 +34,7 @@ export async function init(id, options) {
3434
}
3535
});
3636

37-
const info = await getClientInfo(url);
37+
const info = await getClientInfo(url, { enableIpLocator: enableIpLocator });
3838
info.id = clientId;
3939

4040
const callback = async () => {

0 commit comments

Comments
 (0)