Add support for showing a QR code for a share URL after uploading

This commit is contained in:
timvisee 2019-03-14 22:12:21 +01:00
parent c068e4c143
commit 176775d9cf
No known key found for this signature in database
GPG key ID: B8DB720BC383E172
5 changed files with 115 additions and 1 deletions

View file

@ -109,6 +109,12 @@ impl<'a: 'b, 'b> UploadMatcher<'a> {
None
}
}
/// Check whether to print a QR code for the share URL.
#[cfg(feature = "qrcode")]
pub fn qrcode(&self) -> bool {
self.matches.is_present("qrcode")
}
}
impl<'a> Matcher<'a> for UploadMatcher<'a> {