Skip to content

Commit 6a83450

Browse files
committed
Unset the optional bit for a feature when setting the required bit
There is no reason to set both, and this currently makes testing the new BOLT invoice tests slightly harder, so we just unset it.
1 parent 9463923 commit 6a83450

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

lightning/src/ln/features.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -308,6 +308,7 @@ mod sealed {
308308
}
309309

310310
flags[Self::BYTE_OFFSET] |= Self::REQUIRED_MASK;
311+
flags[Self::BYTE_OFFSET] &= !Self::OPTIONAL_MASK;
311312
}
312313

313314
/// Sets the feature's optional (odd) bit in the given flags.

0 commit comments

Comments
 (0)