mirror of
https://github.com/esiur/esiur-dotnet.git
synced 2026-04-03 20:08:21 +00:00
WIP
This commit is contained in:
@@ -119,10 +119,10 @@ public partial class MyService
|
||||
int MyPasscode = 2025;
|
||||
public PropertyContext<int> Passcode
|
||||
{
|
||||
get => new((sender) => sender.Session.AuthorizedAccount == "alice" ? MyPasscode : 0);
|
||||
get => new((sender) => sender.Session.AuthorizedIdentity == "alice" ? MyPasscode : 0);
|
||||
set
|
||||
{
|
||||
if (value.Connection.Session.AuthorizedAccount != "alice")
|
||||
if (value.Connection.Session.AuthorizedIdentity != "alice")
|
||||
throw new Exception("Only Alice is allowed.");
|
||||
MyPasscode = value.Value;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user