🐛 Fix getting publisher
This commit is contained in:
parent
87b6bee1f3
commit
ed77a443b8
@ -68,7 +68,7 @@ func FilterPostWithUserContext(c *fiber.Ctx, tx *gorm.DB, user *authm.Account) *
|
|||||||
} else {
|
} else {
|
||||||
// Get itself
|
// Get itself
|
||||||
var publisher models.Publisher
|
var publisher models.Publisher
|
||||||
if err := database.C.Where("id = ?", user.ID).First(&publisher).Error; err != nil {
|
if err := database.C.Where("account_id = ?", user.ID).First(&publisher).Error; err != nil {
|
||||||
return tx
|
return tx
|
||||||
}
|
}
|
||||||
allowlist = append(allowlist, publisher.ID)
|
allowlist = append(allowlist, publisher.ID)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user