mirror of
http://git.whoc.org.uk/git/password-manager.git
synced 2024-11-14 18:29:02 +01:00
Updated weird case path adding a sensible result and logging a warning
This commit is contained in:
parent
0dbd7eb45a
commit
cbc613da7f
@ -581,7 +581,8 @@ Clipperz.Base.extend(Clipperz.PM.DataModel.Record, Clipperz.PM.DataModel.Encrypt
|
||||
result = someFilteredResults[0];
|
||||
break;
|
||||
default:
|
||||
WTF = TODO;
|
||||
console.log("Warning: Record.fieldWithLabel('" + aLabel + "') is returning more than one result: " + someFilteredResults.length);
|
||||
result = someFilteredResults[0];
|
||||
break;
|
||||
}
|
||||
|
||||
|
@ -681,6 +681,7 @@ Clipperz.Base.extend(Clipperz.PM.DataModel.User, Object, {
|
||||
], {trace:false});
|
||||
},
|
||||
*/
|
||||
|
||||
'recordWithLabel': function (aLabel) {
|
||||
return Clipperz.Async.callbacks("User.recordWithLabel", [
|
||||
MochiKit.Base.method(this, 'getRecords'),
|
||||
@ -701,7 +702,8 @@ Clipperz.Base.extend(Clipperz.PM.DataModel.User, Object, {
|
||||
result = someFilteredResults[0];
|
||||
break;
|
||||
default:
|
||||
WTF = TODO;
|
||||
console.log("Warning: User.recordWithLabel('" + aLabel + "') is returning more than one result: " + someFilteredResults.length);
|
||||
result = someFilteredResults[0];
|
||||
break;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user