Skip to content

Commit 1b29a55

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 35b597a commit 1b29a55

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
@@ -275,6 +275,7 @@ mod sealed {
275275
}
276276

277277
flags[Self::BYTE_OFFSET] |= Self::REQUIRED_MASK;
278+
flags[Self::BYTE_OFFSET] &= !Self::OPTIONAL_MASK;
278279
}
279280

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

0 commit comments

Comments
 (0)