geforkt von mirrored/vaultwarden
Merge branch 'master' of https://github.com/dani-garcia/bitwarden_rs into totp-timedrift
Dieser Commit ist enthalten in:
Commit
d989a19f76
2 geänderte Dateien mit 6 neuen und 9 gelöschten Zeilen
|
@ -50,6 +50,6 @@ See the [bitwarden_rs wiki](https://github.com/dani-garcia/bitwarden_rs/wiki) fo
|
||||||
|
|
||||||
## Get in touch
|
## Get in touch
|
||||||
|
|
||||||
To ask an question, [raising an issue](https://github.com/dani-garcia/bitwarden_rs/issues/new) is fine, also please report any bugs spotted here.
|
To ask a question, [raising an issue](https://github.com/dani-garcia/bitwarden_rs/issues/new) is fine. Please also report any bugs spotted here.
|
||||||
|
|
||||||
If you prefer to chat, we're usually hanging around at [#bitwarden_rs:matrix.org](https://matrix.to/#/#bitwarden_rs:matrix.org) room on Matrix. Feel free to join us!
|
If you prefer to chat, we're usually hanging around at [#bitwarden_rs:matrix.org](https://matrix.to/#/#bitwarden_rs:matrix.org) room on Matrix. Feel free to join us!
|
||||||
|
|
|
@ -61,14 +61,7 @@ fn icon(domain: String) -> Content<Vec<u8>> {
|
||||||
return Content(icon_type, FALLBACK_ICON.to_vec());
|
return Content(icon_type, FALLBACK_ICON.to_vec());
|
||||||
}
|
}
|
||||||
|
|
||||||
if check_icon_domain_is_blacklisted(&domain) {
|
Content(icon_type, get_icon(&domain))
|
||||||
warn!("Domain is blacklisted: {:#?}", domain);
|
|
||||||
return Content(icon_type, FALLBACK_ICON.to_vec());
|
|
||||||
}
|
|
||||||
|
|
||||||
let icon = get_icon(&domain);
|
|
||||||
|
|
||||||
Content(icon_type, icon)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
fn check_icon_domain_is_blacklisted(domain: &str) -> bool {
|
fn check_icon_domain_is_blacklisted(domain: &str) -> bool {
|
||||||
|
@ -380,6 +373,10 @@ fn parse_sizes(sizes: Option<String>) -> (u16, u16) {
|
||||||
}
|
}
|
||||||
|
|
||||||
fn download_icon(domain: &str) -> Result<Vec<u8>, Error> {
|
fn download_icon(domain: &str) -> Result<Vec<u8>, Error> {
|
||||||
|
if check_icon_domain_is_blacklisted(domain) {
|
||||||
|
err!("Domain is blacklisted", domain)
|
||||||
|
}
|
||||||
|
|
||||||
let (iconlist, cookie_str) = get_icon_url(&domain)?;
|
let (iconlist, cookie_str) = get_icon_url(&domain)?;
|
||||||
|
|
||||||
let mut buffer = Vec::new();
|
let mut buffer = Vec::new();
|
||||||
|
|
Laden …
In neuem Issue referenzieren