summaryrefslogtreecommitdiff
path: root/src/models
diff options
context:
space:
mode:
authorsyuilo <syuilotan@yahoo.co.jp>2018-04-08 06:55:26 +0900
committersyuilo <syuilotan@yahoo.co.jp>2018-04-08 06:55:26 +0900
commit6e34e77372bd74c85ebf5a6b4214c818231dbe8b (patch)
tree614e46573693bb4e0b6d097fde88a52d1cd0fa1f /src/models
parentFix bug (diff)
downloadsharkey-6e34e77372bd74c85ebf5a6b4214c818231dbe8b.tar.gz
sharkey-6e34e77372bd74c85ebf5a6b4214c818231dbe8b.tar.bz2
sharkey-6e34e77372bd74c85ebf5a6b4214c818231dbe8b.zip
Implement announce
And bug fixes
Diffstat (limited to 'src/models')
-rw-r--r--src/models/note.ts2
-rw-r--r--src/models/notification.ts3
2 files changed, 1 insertions, 4 deletions
diff --git a/src/models/note.ts b/src/models/note.ts
index 9b33bb76f1..f509fa66c8 100644
--- a/src/models/note.ts
+++ b/src/models/note.ts
@@ -112,7 +112,7 @@ export const pack = async (
_note = deepcopy(note);
}
- if (!_note) throw 'invalid note arg.';
+ if (!_note) throw `invalid note arg ${note}`;
const id = _note._id;
diff --git a/src/models/notification.ts b/src/models/notification.ts
index 17144d7ee8..d5ca7135b7 100644
--- a/src/models/notification.ts
+++ b/src/models/notification.ts
@@ -51,9 +51,6 @@ export interface INotification {
/**
* Pack a notification for API response
- *
- * @param {any} notification
- * @return {Promise<any>}
*/
export const pack = (notification: any) => new Promise<any>(async (resolve, reject) => {
let _notification: any;