rename pid -> peerId

This commit is contained in:
Pavel Murygin 2021-01-17 20:29:50 +03:00
parent d4fb811054
commit 7cd14a7ca0
2 changed files with 13 additions and 13 deletions

View File

@ -2,13 +2,13 @@ import { FluenceClient, Particle, sendParticle, sendParticleAsFetch } from '@flu
import {
fluentPadServiceId,
historyNodePid,
historyNodePeerId,
historyServiceId,
notifyOnlineFnName,
notifyTextUpdateFnName,
notifyUserAddedFnName,
notifyUserRemovedFnName,
userListNodePid,
userListNodePeerId,
userListServiceId,
} from './constants';
@ -71,7 +71,7 @@ export const updateOnlineStatuses = async (client: FluenceClient) => {
)
`,
{
userlistNode: userListNodePid,
userlistNode: userListNodePeerId,
userlist: userListServiceId,
myRelay: client.relayPeerId,
myPeerId: client.selfPeerId,
@ -103,7 +103,7 @@ export const notifySelfAdded = (client: FluenceClient, name: string) => {
)
`,
{
userlistNode: userListNodePid,
userlistNode: userListNodePeerId,
userlist: userListServiceId,
myRelay: client.relayPeerId,
myPeerId: client.selfPeerId,
@ -138,7 +138,7 @@ export const getUserList = async (client: FluenceClient) => {
)
`,
{
userlistNode: userListNodePid,
userlistNode: userListNodePeerId,
userlist: userListServiceId,
myRelay: client.relayPeerId,
myPeerId: client.selfPeerId,
@ -174,7 +174,7 @@ export const join = async (client: FluenceClient, nickName: string) => {
relay_id: client.relayPeerId,
},
userlist: userListServiceId,
userlistNode: userListNodePid,
userlistNode: userListNodePeerId,
},
);
@ -205,7 +205,7 @@ export const leave = async (client: FluenceClient) => {
)
`,
{
userlistNode: userListNodePid,
userlistNode: userListNodePeerId,
userlist: userListServiceId,
myRelay: client.relayPeerId,
myPeerId: client.selfPeerId,
@ -239,8 +239,8 @@ export const getHistory = async (client: FluenceClient) => {
myPeerId: client.selfPeerId,
userlist: userListServiceId,
history: historyServiceId,
userlistNode: userListNodePid,
historyNode: historyNodePid,
userlistNode: userListNodePeerId,
historyNode: historyNodePeerId,
},
);
@ -276,8 +276,8 @@ export const addEntry = async (client: FluenceClient, entry: string) => {
`,
{
userlistNode: userListNodePid,
historyNode: historyNodePid,
userlistNode: userListNodePeerId,
historyNode: historyNodePeerId,
entry: entry,
userlist: userListServiceId,
history: historyServiceId,

View File

@ -10,7 +10,7 @@ export const notifyTextUpdateFnName = 'notifyTextUpdate';
export const userListServiceId = '03edcc81-7777-4234-b048-36305d8d65e2';
export const historyServiceId = '7fb57031-1d3d-4391-9a9f-da40a6c4963d';
export const userListNodePid = dev[2].peerId;
export const historyNodePid = dev[2].peerId;
export const userListNodePeerId = dev[2].peerId;
export const historyNodePeerId = dev[2].peerId;
export const relayNode = dev[0];