mirror of
https://github.com/xivdev/Penumbra.git
synced 2026-02-20 06:47:46 +01:00
Anonymized collection names for log
This commit is contained in:
parent
b5698acebf
commit
1c60a61f79
5 changed files with 21 additions and 22 deletions
|
|
@ -22,6 +22,11 @@ public partial class ModCollection
|
|||
// The collection name can contain invalid path characters,
|
||||
// but after removing those and going to lower case it has to be unique.
|
||||
public string Name { get; private init; }
|
||||
|
||||
// Get the first two letters of a collection name and its Index (or None if it is the empty collection).
|
||||
public string AnonymizedName
|
||||
=> this == Empty ? Empty.Name : Name.Length > 2 ? $"{Name[..2]}... ({Index})" : $"{Name} ({Index})";
|
||||
|
||||
public int Version { get; private set; }
|
||||
public int Index { get; private set; } = -1;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue