diff options
author | Chocobozzz <florian.bigard@gmail.com> | 2017-06-16 09:54:59 +0200 |
---|---|---|
committer | Chocobozzz <florian.bigard@gmail.com> | 2017-06-16 09:54:59 +0200 |
commit | 70c065d64c330196d371941d9294a55da6e3aa37 (patch) | |
tree | 4532a9611502135bedb1cc6009c706e31f1f9be4 /server/models/pod/pod.ts | |
parent | 74889a71fe687dda74f2a687653122327807af36 (diff) | |
download | PeerTube-70c065d64c330196d371941d9294a55da6e3aa37.tar.gz PeerTube-70c065d64c330196d371941d9294a55da6e3aa37.tar.zst PeerTube-70c065d64c330196d371941d9294a55da6e3aa37.zip |
Add this context to instance model functions
Diffstat (limited to 'server/models/pod/pod.ts')
-rw-r--r-- | server/models/pod/pod.ts | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/server/models/pod/pod.ts b/server/models/pod/pod.ts index 4c6e63024..4fe7fda1c 100644 --- a/server/models/pod/pod.ts +++ b/server/models/pod/pod.ts | |||
@@ -96,12 +96,12 @@ export default function (sequelize: Sequelize.Sequelize, DataTypes: Sequelize.Da | |||
96 | 96 | ||
97 | // ------------------------------ METHODS ------------------------------ | 97 | // ------------------------------ METHODS ------------------------------ |
98 | 98 | ||
99 | toFormatedJSON = function () { | 99 | toFormatedJSON = function (this: PodInstance) { |
100 | const json = { | 100 | const json = { |
101 | id: this.id, | 101 | id: this.id, |
102 | host: this.host, | 102 | host: this.host, |
103 | email: this.email, | 103 | email: this.email, |
104 | score: this.score, | 104 | score: this.score as number, |
105 | createdAt: this.createdAt | 105 | createdAt: this.createdAt |
106 | } | 106 | } |
107 | 107 | ||