File tree Expand file tree Collapse file tree 3 files changed +3
-9
lines changed
crates/feedparser-rs-core/src Expand file tree Collapse file tree 3 files changed +3
-9
lines changed Original file line number Diff line number Diff line change @@ -393,11 +393,7 @@ fn is_dc_tag(name: &[u8]) -> Option<&str> {
393393 if name. starts_with ( b"dc:" ) {
394394 let tag_name = std:: str:: from_utf8 ( & name[ 3 ..] ) . ok ( ) ?;
395395 // Validate: non-empty and alphanumeric + hyphen only
396- if !tag_name. is_empty ( )
397- && tag_name
398- . chars ( )
399- . all ( |c| c. is_alphanumeric ( ) || c == '-' )
400- {
396+ if !tag_name. is_empty ( ) && tag_name. chars ( ) . all ( |c| c. is_alphanumeric ( ) || c == '-' ) {
401397 Some ( tag_name)
402398 } else {
403399 None
Original file line number Diff line number Diff line change @@ -100,9 +100,7 @@ fn is_private_ip(ip: &IpAddr) -> bool {
100100 || octets[ 0 ] == 127
101101 }
102102 IpAddr :: V6 ( ipv6) => {
103- ipv6. is_loopback ( )
104- || ipv6. is_unspecified ( )
105- || ( ipv6. segments ( ) [ 0 ] & 0xfe00 ) == 0xfc00
103+ ipv6. is_loopback ( ) || ipv6. is_unspecified ( ) || ( ipv6. segments ( ) [ 0 ] & 0xfe00 ) == 0xfc00
106104 }
107105 }
108106}
Original file line number Diff line number Diff line change @@ -10,5 +10,5 @@ pub mod sanitize;
1010pub mod text;
1111
1212// Re-export commonly used functions
13- pub use base_url:: { is_safe_url , BaseUrlContext , combine_bases, resolve_url} ;
13+ pub use base_url:: { BaseUrlContext , combine_bases, is_safe_url , resolve_url} ;
1414pub use date:: parse_date;
You can’t perform that action at this time.
0 commit comments