Truncate member profile in long system list

This commit is contained in:
Ske
2019-08-04 13:43:56 +02:00
parent a201ad644e
commit fe22ba4f32
2 changed files with 3 additions and 7 deletions

View File

@@ -41,11 +41,6 @@ namespace PluralKit
return Convert.ToBase64String(buf);
}
public static string Truncate(this string str, int maxLength, string ellipsis = "...") {
if (str.Length < maxLength) return str;
return str.Substring(0, maxLength - ellipsis.Length) + ellipsis;
}
public static bool IsLongerThan(this string str, int length)
{
if (str != null) return str.Length > length;