Skip to content

Commit

Permalink
default ValueRule::optional
Browse files Browse the repository at this point in the history
  • Loading branch information
slivingston committed Nov 2, 2024
1 parent 5e53655 commit 0778c9f
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions src/bin/rrhttp.rs
Original file line number Diff line number Diff line change
Expand Up @@ -300,7 +300,9 @@ enum ValueType {

#[derive(Clone, Debug, Deserialize, PartialEq)]
struct ValueRule {
#[serde(default)]
optional: bool,

name: String,

#[serde(rename = "type")]
Expand Down Expand Up @@ -746,19 +748,15 @@ rules:
default: block
schema:
- name: Pitch
optional: false
type: float
range: [-40, 0]
- name: Roll
optional: false
type: float
range: [-15, 15]
- name: Yaw
optional: false
type: float
range: [-75, 75]
- name: Velocity
optional: false
type: int
range: [1, 75]
";
Expand Down

0 comments on commit 0778c9f

Please sign in to comment.