minor
This commit is contained in:
@@ -1,7 +1,5 @@
|
|||||||
const config = require('config')
|
const config = require('config')
|
||||||
const moment = require('moment-timezone')
|
const moment = require('moment-timezone')
|
||||||
const settingsController = require('../controller/settings')
|
|
||||||
// const debug = require('debug')('event:modals')
|
|
||||||
|
|
||||||
module.exports = (sequelize, DataTypes) => {
|
module.exports = (sequelize, DataTypes) => {
|
||||||
const Event = sequelize.define('event', {
|
const Event = sequelize.define('event', {
|
||||||
@@ -52,16 +50,16 @@ module.exports = (sequelize, DataTypes) => {
|
|||||||
${this.description.length > 500 ? this.description.substr(0, 500) + '...' : this.description}<br/>
|
${this.description.length > 500 ? this.description.substr(0, 500) + '...' : this.description}<br/>
|
||||||
${tag_links} <br/>`
|
${tag_links} <br/>`
|
||||||
|
|
||||||
const attachment = []
|
// const attachment = []
|
||||||
if (this.image_path) {
|
// if (this.image_path) {
|
||||||
attachment.push({
|
// attachment.push({
|
||||||
type: 'Document',
|
// type: 'Document',
|
||||||
mediaType: 'image/jpeg',
|
// mediaType: 'image/jpeg',
|
||||||
url: `${config.baseurl}/media/${this.image_path}`,
|
// url: `${config.baseurl}/media/${this.image_path}`,
|
||||||
name: null,
|
// name: null,
|
||||||
blurHash: null
|
// blurHash: null
|
||||||
})
|
// })
|
||||||
}
|
// }
|
||||||
|
|
||||||
return {
|
return {
|
||||||
id: `${config.baseurl}/federation/m/${this.id}`,
|
id: `${config.baseurl}/federation/m/${this.id}`,
|
||||||
|
|||||||
@@ -91,7 +91,7 @@ module.exports = {
|
|||||||
if (!name) { return res.status(400).send('Bad request.') }
|
if (!name) { return res.status(400).send('Bad request.') }
|
||||||
if (name !== req.settings.instance_name) { return res.status(404).send(`No record found for ${name}`) }
|
if (name !== req.settings.instance_name) { return res.status(404).send(`No record found for ${name}`) }
|
||||||
|
|
||||||
const events = await Event.findAll( { include: [Tag, Place] })
|
const events = await Event.findAll({ include: [Tag, Place] })
|
||||||
|
|
||||||
debug('Inside outbox, should return all events from this user')
|
debug('Inside outbox, should return all events from this user')
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user