mirror of
https://github.com/stoatchat/for-legacy-web.git
synced 2026-03-08 01:45:28 +00:00
feat: add ServerInfo, port ChannelInfo
This commit is contained in:
16
src/controllers/safety/index.ts
Normal file
16
src/controllers/safety/index.ts
Normal file
@@ -0,0 +1,16 @@
|
||||
import { Server } from "revolt.js";
|
||||
|
||||
export function report(object: Server) {
|
||||
let type;
|
||||
if (object instanceof Server) {
|
||||
type = "Server";
|
||||
}
|
||||
|
||||
window.open(
|
||||
`mailto:abuse@revolt.chat?subject=${encodeURIComponent(
|
||||
`${type} Report`,
|
||||
)}&body=${encodeURIComponent(
|
||||
`${type} ID: ${object._id}\nWrite more information here!`,
|
||||
)}`,
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user