Skip to content

Commit 86a4055

Browse files
committed
Refactor ConfigEditor
Moving function into base class
1 parent 5d94e1b commit 86a4055

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

com.playeveryware.eos/Runtime/Core/Config/Config.cs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -547,8 +547,11 @@ protected virtual void BeforeWrite()
547547

548548
protected virtual void OnWriteCompleted()
549549
{
550-
// Optionally override for deriving classes. Default behavior is to
551-
// take no action.
550+
// Optionally override for deriving classes. Base implementation performs Unity Editor persistence operations.
551+
#if UNITY_EDITOR
552+
UnityEditor.AssetDatabase.SaveAssets();
553+
UnityEditor.AssetDatabase.Refresh();
554+
#endif
552555
}
553556

554557
#endif

com.playeveryware.eos/Runtime/Core/Config/ProductConfig.cs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -335,10 +335,6 @@ protected override void OnWriteCompleted()
335335

336336
// Update the platform config client credentials if needed.
337337
UpdatePlatformConfigClientCredentials();
338-
#if UNITY_EDITOR
339-
UnityEditor.AssetDatabase.SaveAssets();
340-
UnityEditor.AssetDatabase.Refresh();
341-
#endif
342338
}
343339

344340
#endif

0 commit comments

Comments
 (0)