mirror of
https://github.com/estruyf/vscode-front-matter.git
synced 2026-08-06 08:52:47 +02:00
#113 - Move the database init code
This commit is contained in:
@@ -42,8 +42,6 @@ export class Dashboard {
|
||||
* Init the dashboard
|
||||
*/
|
||||
public static async init() {
|
||||
this.mediaLib = MediaLibrary.getInstance();
|
||||
|
||||
const openOnStartup = SettingsHelper.get(SETTINGS_DASHBOARD_OPENONSTART);
|
||||
if (openOnStartup) {
|
||||
Dashboard.open();
|
||||
@@ -54,6 +52,8 @@ export class Dashboard {
|
||||
* Open or reveal the dashboard
|
||||
*/
|
||||
public static async open(data?: DashboardData) {
|
||||
this.mediaLib = MediaLibrary.getInstance();
|
||||
|
||||
Dashboard._viewData = data;
|
||||
|
||||
if (Dashboard.isOpen) {
|
||||
|
||||
Reference in New Issue
Block a user