Skip to content

Commit

Permalink
Add Comment feature (#24)
Browse files Browse the repository at this point in the history
  • Loading branch information
HynoR authored Apr 20, 2024
1 parent 9b2a3ef commit e80cec6
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/config.rs
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,9 @@ pub fn read_config(conf: String) -> Vec<NatCell> {

let strs = contents.split('\n');
for str in strs {
if str.starts_with('#'){
continue;
}
let cells = str.trim().split(',').collect::<Vec<&str>>();
if cells.len() == 4 || cells.len() == 5 {
let mut protocal: Protocol = Protocol::All;
Expand Down Expand Up @@ -177,4 +180,4 @@ pub fn read_config(conf: String) -> Vec<NatCell> {
}
}
nat_cells
}
}

0 comments on commit e80cec6

Please sign in to comment.