mirror of
https://github.com/nasa/openmct.git
synced 2025-06-18 15:18:12 +00:00
[Persistence] Use ids from TransactionManager API
Recommended during code review, https://github.com/nasa/openmct/pull/1084#discussion_r71021889
This commit is contained in:
@ -60,7 +60,7 @@ define(
|
||||
|
||||
if (this.transactionManager.isActive()) {
|
||||
this.transactionManager.addToTransaction(
|
||||
this.domainObject,
|
||||
this.domainObject.getId(),
|
||||
wrappedPersistence.persist.bind(wrappedPersistence),
|
||||
wrappedPersistence.refresh.bind(wrappedPersistence)
|
||||
);
|
||||
@ -72,7 +72,8 @@ define(
|
||||
};
|
||||
|
||||
TransactionalPersistenceCapability.prototype.refresh = function () {
|
||||
this.transactionManager.clearTransactionsFor(this.domainObject);
|
||||
this.transactionManager
|
||||
.clearTransactionsFor(this.domainObject.getId());
|
||||
return this.persistenceCapability.refresh();
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user