Ensure upper range is included in a |test:1..10| model

This commit is contained in:
Tobie Morgan Hitchcock 2022-03-17 22:26:34 +00:00
parent 73df91a438
commit f509b88109
2 changed files with 2 additions and 2 deletions

View file

@ -79,7 +79,7 @@ impl Model {
} }
} }
if let Some(r) = self.range { if let Some(r) = self.range {
for x in r.0..r.1 { for x in r.0..=r.1 {
Thing { Thing {
tb: self.table.to_string(), tb: self.table.to_string(),
id: x.to_string(), id: x.to_string(),

View file

@ -82,7 +82,7 @@ impl Model {
} }
} }
if let Some(r) = self.range { if let Some(r) = self.range {
for x in r.0..r.1 { for x in r.0..=r.1 {
Thing { Thing {
tb: self.table.to_string(), tb: self.table.to_string(),
id: x.to_string(), id: x.to_string(),