mirror of
https://github.com/zotero/zotero.git
synced 2026-10-05 02:43:38 +00:00
Fix error that breaks the item tree after creating a new empty note from the new item menu
(ItemTreeView's getField() had a bug -- switched to just use Item.getField(), which already handles notes properly)
This commit is contained in:
parent
7fed86b389
commit
66729ed1e2
1 changed files with 1 additions and 16 deletions
|
|
@ -993,22 +993,7 @@ Scholar.ItemTreeView.TreeRow.prototype.isRegularItem = function()
|
|||
|
||||
Scholar.ItemTreeView.TreeRow.prototype.getField = function(field)
|
||||
{
|
||||
if(this.isNote() && field == 'title')
|
||||
{
|
||||
var t = this.ref.getNote();
|
||||
if(t)
|
||||
{
|
||||
var n = t.indexOf("\n");
|
||||
if(n > -1)
|
||||
t = t.substring(0,n);
|
||||
return t;
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
return this.ref.getField(field);
|
||||
}
|
||||
|
||||
return this.ref.getField(field);
|
||||
}
|
||||
|
||||
Scholar.ItemTreeView.TreeRow.prototype.getType = function()
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue