Skip to content

Commit d279f65

Browse files
committed
rename properties
1 parent 538e9a8 commit d279f65

File tree

2 files changed

+15
-15
lines changed

2 files changed

+15
-15
lines changed

src/dev-connection/index.test.ts

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -351,23 +351,23 @@ describe('dev-connection', () => {
351351
expect(el.chain.getValue()).to.be.equal(undefined)
352352
})
353353
})
354-
describe('Exposes identifiers', () => {
355-
it('identifiers is undefined by default', () => {
354+
describe('Exposes identifier', () => {
355+
it('identifier is undefined by default', () => {
356356
const el = connection()
357-
expect(el.identifiers.getValue()).to.be.equal(undefined)
357+
expect(el.identifier.getValue()).to.be.equal(undefined)
358358
})
359-
it('identifiers is BehaviorSubject', () => {
359+
it('identifier is BehaviorSubject', () => {
360360
const el = connection()
361361
let _count = 0
362-
el.identifiers.subscribe(() => {
362+
el.identifier.subscribe(() => {
363363
_count = _count + 1
364364
})
365-
expect(el.identifiers.getValue()).to.be.equal(undefined)
365+
expect(el.identifier.getValue()).to.be.equal(undefined)
366366

367-
const ids = { email: 'my@mail.com' }
368-
el.identifiers.next(ids)
367+
const id = { email: 'my@mail.com' }
368+
el.identifier.next(id)
369369

370-
expect(el.identifiers.getValue()).to.be.equal(ids)
370+
expect(el.identifier.getValue()).to.be.equal(id)
371371
expect(_count).to.be.equal(2)
372372
})
373373
})

src/dev-connection/index.ts

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ const newAccount = () => new BehaviorSubject<UndefinedOr<string>>(undefined)
3030
const newChain = () => new BehaviorSubject<UndefinedOr<number>>(undefined)
3131
const newEip1193Provider = () =>
3232
new BehaviorSubject<UndefinedOr<Eip1193Provider>>(undefined)
33-
const newIdentifiers = () =>
33+
const newIdentifier = () =>
3434
new BehaviorSubject<UndefinedOr<{ email?: string }>>(undefined)
3535

3636
const testEventEmitterable = (
@@ -51,7 +51,7 @@ export class Connection extends UllrElement {
5151
private _account!: BehaviorSubject<UndefinedOr<string>>
5252
private _chain!: BehaviorSubject<UndefinedOr<number>>
5353
private _eip1193Provider!: BehaviorSubject<UndefinedOr<Eip1193Provider>>
54-
private _identifiers!: BehaviorSubject<UndefinedOr<{ email?: string }>>
54+
private _identifier!: BehaviorSubject<UndefinedOr<{ email?: string }>>
5555
private _signerSubscription!: Subscription
5656
private _providerSubscription!: Subscription
5757
private _chainChangedListener = (chainId: number | string) => {
@@ -90,8 +90,8 @@ export class Connection extends UllrElement {
9090
return this._eip1193Provider
9191
}
9292

93-
get identifiers() {
94-
return this._identifiers
93+
get identifier() {
94+
return this._identifier
9595
}
9696

9797
async setEip1193Provider(
@@ -123,7 +123,7 @@ export class Connection extends UllrElement {
123123
this._account = newAccount()
124124
this._chain = newChain()
125125
this._eip1193Provider = newEip1193Provider()
126-
this._identifiers = newIdentifiers()
126+
this._identifier = newIdentifier()
127127

128128
this._signerSubscription = this.signer.asObservable().subscribe((x) => {
129129
if (x === undefined) {
@@ -158,6 +158,6 @@ export class Connection extends UllrElement {
158158
this.provider.complete()
159159
this.account.complete()
160160
this.chain.complete()
161-
this.identifiers.complete()
161+
this.identifier.complete()
162162
}
163163
}

0 commit comments

Comments
 (0)