mirror of
https://codeberg.org/forgejo/forgejo.git
synced 2026-05-13 06:20:24 +00:00
The endpoint returning individual activities was missing access control checks, since IDs are sequential, this is not ideal. Fixes #12333 Reviewed-on: https://codeberg.org/forgejo/forgejo/pulls/12382 Reviewed-by: Gusted <gusted@noreply.codeberg.org>
14 lines
297 B
Go
14 lines
297 B
Go
// Copyright 2026 The Forgejo Authors. All rights reserved.
|
|
// SPDX-License-Identifier: GPL-3.0-or-later
|
|
|
|
package activities
|
|
|
|
import "fmt"
|
|
|
|
type ErrActivityPrivate struct {
|
|
id int64
|
|
}
|
|
|
|
func (err ErrActivityPrivate) Error() string {
|
|
return fmt.Sprintf("Activity with id %d is private", err.id)
|
|
}
|