Remove dependence on network.Connection.Scope

This commit is contained in:
Daniel
2021-04-16 17:44:01 +02:00
parent a879d2715a
commit 4c5461a788
3 changed files with 9 additions and 9 deletions

View File

@@ -106,10 +106,10 @@ func createPrompt(ctx context.Context, conn *network.Connection, pkt packet.Pack
switch {
case conn.Inbound, conn.Entity.Domain == "": // connection to/from IP
nID = fmt.Sprintf(
"%s-%s-%s-%s",
"%s-%s-%v-%s",
promptIDPrefix,
localProfile.ID,
conn.Scope,
conn.Inbound,
pkt.Info().RemoteIP(),
)
default: // connection to domain
@@ -117,7 +117,7 @@ func createPrompt(ctx context.Context, conn *network.Connection, pkt packet.Pack
"%s-%s-%s",
promptIDPrefix,
localProfile.ID,
conn.Scope,
conn.Entity.Domain,
)
}