Skip to content
This repository has been archived by the owner on Apr 11, 2024. It is now read-only.

Commit

Permalink
Work around private thing
Browse files Browse the repository at this point in the history
  • Loading branch information
ragalie committed Jul 27, 2023
1 parent 728504c commit 19e9f48
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions rest/base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -243,14 +243,14 @@ export class Base {
return instance;
}

#session: Session;
psession: Session;

get session(): Session {
return this.#session;
return this.psession;
}

constructor({session, fromData}: BaseConstructorArgs) {
this.#session = session;
this.psession = session;

if (fromData) {
this.setData(fromData);
Expand Down Expand Up @@ -298,7 +298,7 @@ export class Base {

return Object.entries(this).reduce((acc: Body, [attribute, value]) => {
if (
['#session'].includes(attribute) ||
['psession'].includes(attribute) ||
(saving && readOnlyAttributes.includes(attribute))
) {
return acc;
Expand Down

0 comments on commit 19e9f48

Please sign in to comment.