mirror of
https://github.com/ZeppelinBot/Zeppelin.git
synced 2025-05-11 04:45:02 +00:00
Add !message/!messageinfo command
This commit is contained in:
parent
60aff76ebe
commit
e8ff297368
9 changed files with 210 additions and 0 deletions
|
@ -492,6 +492,13 @@ export function trimLines(str: string) {
|
|||
.trim();
|
||||
}
|
||||
|
||||
export function trimEmptyLines(str: string) {
|
||||
return str
|
||||
.split("\n")
|
||||
.filter(l => l.trim() !== "")
|
||||
.join("\n");
|
||||
}
|
||||
|
||||
export function asSingleLine(str: string) {
|
||||
return trimLines(str).replace(/\n/g, " ");
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue