forked from sagi/seepur
18 lines
359 B
JavaScript
18 lines
359 B
JavaScript
'use strict'
|
|
|
|
/** @type {typeof import('@adonisjs/lucid/src/Lucid/Model')} */
|
|
const Model = use('Model')
|
|
const User = use('App/Models/User');
|
|
|
|
class Call extends Model {
|
|
async getUsers() {
|
|
const users = [
|
|
(await User.find(this.user_1)).toJSON(),
|
|
(await User.find(this.user_2)).toJSON()
|
|
];
|
|
|
|
return users;
|
|
}
|
|
}
|
|
|
|
module.exports = Call
|