From b976c84a29aa74f0dd8bd69c4e0d4847db9218ea Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Tue, 22 Sep 2015 01:26:48 -0400 Subject: [PATCH] Add Zotero.Libraries.userLibrary --- chrome/content/zotero/xpcom/data/libraries.js | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/chrome/content/zotero/xpcom/data/libraries.js b/chrome/content/zotero/xpcom/data/libraries.js index a228892de9..cec3e365b6 100644 --- a/chrome/content/zotero/xpcom/data/libraries.js +++ b/chrome/content/zotero/xpcom/data/libraries.js @@ -34,6 +34,13 @@ Zotero.Libraries = new function () { } }); + let _userLibrary; + Zotero.defineProperty(this, 'userLibrary', { + get: function () { + return _userLibrary || (_userLibrary = Zotero.Libraries.get(this.userLibraryID)); + } + }) + let _publicationsLibraryID; Zotero.defineProperty(this, 'publicationsLibraryID', { get: function() {