mirror of
https://github.com/ragestudio/comty.git
synced 2025-06-10 02:54:15 +00:00
format
This commit is contained in:
parent
1d42463c85
commit
4d4b9b3050
@ -10,13 +10,13 @@ export default class PublicController extends Controller {
|
|||||||
"/featured_wallpapers": {
|
"/featured_wallpapers": {
|
||||||
fn: async (req, res) => {
|
fn: async (req, res) => {
|
||||||
const featuredWallpapers = await FeaturedWallpaper.find({})
|
const featuredWallpapers = await FeaturedWallpaper.find({})
|
||||||
.sort({ date: -1 })
|
.sort({ date: -1 })
|
||||||
.limit(10)
|
.limit(10)
|
||||||
.catch(err => {
|
.catch(err => {
|
||||||
return res.status(500).json({
|
return res.status(500).json({
|
||||||
error: err.message
|
error: err.message
|
||||||
}).end()
|
}).end()
|
||||||
})
|
})
|
||||||
|
|
||||||
return res.json(featuredWallpapers)
|
return res.json(featuredWallpapers)
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user