Skip to content

Commit d6b7687

Browse files
committed
more bad merge
1 parent ce086d9 commit d6b7687

File tree

2 files changed

+9
-7
lines changed

2 files changed

+9
-7
lines changed

src/StackExchange.Redis/RedisDatabase.cs

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4602,9 +4602,11 @@ private Message GetStreamAddMessage(RedisKey key, RedisValue entryId, long? maxL
46024602
var includeApproxLen = maxLength.HasValue && useApproximateMaxLength ? 1 : 0;
46034603

46044604
var totalLength = (streamPairs.Length * 2) // Room for the name/value pairs
4605-
+ 1 // The stream entry ID
4606-
+ includeMaxLen // 2 or 0 (MAXLEN keyword & the count)
4607-
+ includeApproxLen; // 1 or 0
4605+
+ 1 // The stream entry ID
4606+
+ (maxLength.HasValue ? 2 : 0) // MAXLEN N
4607+
+ (maxLength.HasValue && useApproximateMaxLength ? 1 : 0) // ~
4608+
+ (mode == StreamTrimMode.KeepReferences ? 0 : 1) // relevant trim-mode keyword
4609+
+ (limit.HasValue ? 2 : 0); // LIMIT N
46084610

46094611
var values = new RedisValue[totalLength];
46104612

@@ -5047,7 +5049,7 @@ private Message GetStringSetMessage(
50475049
When when = When.Always,
50485050
CommandFlags flags = CommandFlags.None)
50495051
{
5050-
when.AlwaysOrExists();
5052+
when.AlwaysOrExistsOrNotExists();
50515053
if (value.IsNull) return Message.Create(Database, flags, RedisCommand.DEL, key);
50525054

50535055
if (expiry == null || expiry.Value == TimeSpan.MaxValue)
@@ -5096,7 +5098,7 @@ private Message GetStringSetAndGetMessage(
50965098
When when = When.Always,
50975099
CommandFlags flags = CommandFlags.None)
50985100
{
5099-
when.AlwaysOrExists();
5101+
when.AlwaysOrExistsOrNotExists();
51005102
if (value.IsNull) return Message.Create(Database, flags, RedisCommand.GETDEL, key);
51015103

51025104
if (expiry == null || expiry.Value == TimeSpan.MaxValue)

src/StackExchange.Redis/ServerEndPoint.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -74,8 +74,8 @@ public ServerEndPoint(ConnectionMultiplexer multiplexer, EndPoint endpoint)
7474
private RedisServer? _defaultServer;
7575
public RedisServer GetRedisServer(object? asyncState)
7676
=> asyncState is null
77-
? (_defaultServer ??= new RedisServer(this, null)) // reuse and memoize
78-
: new RedisServer(this, asyncState);
77+
? (_defaultServer ??= new RedisServer(this, null)) // reuse and memoize
78+
: new RedisServer(this, asyncState);
7979

8080
public EndPoint EndPoint { get; }
8181

0 commit comments

Comments
 (0)