Add-ish support for tags and mentions in new messages
Some checks failed
/ docker (push) Has been cancelled
Some checks failed
/ docker (push) Has been cancelled
This commit is contained in:
parent
94106bb82f
commit
b0f041e7b0
14 changed files with 242 additions and 53 deletions
|
@ -1,7 +1,9 @@
|
|||
package webshared
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"slices"
|
||||
"strings"
|
||||
"time"
|
||||
|
||||
"git.mstar.dev/mstar/linstrom/config"
|
||||
|
@ -118,3 +120,11 @@ func (u *User) FromModel(m *models.User) {
|
|||
u.Verified = &m.Verified
|
||||
u.FinishedRegistration = &m.FinishedRegistration
|
||||
}
|
||||
|
||||
func UserPublicUrl(id string) string {
|
||||
if strings.HasPrefix(id, "http") {
|
||||
return id
|
||||
} else {
|
||||
return fmt.Sprintf("%s/api/activitypub/user/%s", config.GlobalConfig.General.GetFullPublicUrl(), id)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue