Skip to content

Commit 59d5cd6

Browse files
committed
AccessLink Refactor
1 parent 5bae202 commit 59d5cd6

File tree

1 file changed

+10
-11
lines changed

1 file changed

+10
-11
lines changed

Plugins/Flow.Launcher.Plugin.Explorer/Search/QuickAccessLinks/AccessLink.cs

Lines changed: 10 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -9,21 +9,20 @@ public class AccessLink
99
public string Path { get; set; }
1010

1111
public ResultType Type { get; set; } = ResultType.Folder;
12-
13-
[JsonIgnore]
14-
public string Name
12+
13+
public string Name { get; set; }
14+
15+
private string GetPathName()
1516
{
16-
get
17-
{
18-
var path = Path.EndsWith(Constants.DirectorySeparator) ? Path[0..^1] : Path;
17+
var path = Path.EndsWith(Constants.DirectorySeparator) ? Path[0..^1] : Path;
1918

20-
if (path.EndsWith(':'))
21-
return path[0..^1] + " Drive";
19+
if (path.EndsWith(':'))
20+
return path[0..^1] + " Drive";
2221

23-
return path.Split(new[] { System.IO.Path.DirectorySeparatorChar }, StringSplitOptions.None)
24-
.Last();
25-
}
22+
return path.Split(new[] { System.IO.Path.DirectorySeparatorChar }, StringSplitOptions.None)
23+
.Last();
2624
}
25+
2726
}
2827

2928
}

0 commit comments

Comments
 (0)