Skip to content

Commit 203185f

Browse files
release 0.1.3
1 parent ed36127 commit 203185f

File tree

3 files changed

+12
-10
lines changed

3 files changed

+12
-10
lines changed

Cargo.lock

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
[package]
44
name = "mstickereditor"
5-
version = "0.1.2"
5+
version = "0.1.3"
66
edition = "2021"
77
license = "Apache-2.0"
88
description= "import sticker packs from telegram, to be used at the Maunium sticker picker for Matrix"

src/sub_commands/import.rs

+10-8
Original file line numberDiff line numberDiff line change
@@ -247,14 +247,16 @@ fn import_pack(pack: &String, config: &Config, opt: &Opt) -> anyhow::Result<()>
247247
pb.finish();
248248

249249
// write new entries into the database
250-
if let Some(ref mut db) = database {
251-
for sticker in &stickers {
252-
let hash_url = HashUrl {
253-
hash: sticker.file_hash,
254-
url: sticker.mxc_url.clone()
255-
};
256-
writeln!(db, "{}", serde_json::to_string(&hash_url)?)?;
257-
// TODO write into database_tree
250+
if !opt.noupload {
251+
if let Some(ref mut db) = database {
252+
for sticker in &stickers {
253+
let hash_url = HashUrl {
254+
hash: sticker.file_hash,
255+
url: sticker.mxc_url.clone()
256+
};
257+
writeln!(db, "{}", serde_json::to_string(&hash_url)?)?;
258+
// TODO write into database_tree
259+
}
258260
}
259261
}
260262

0 commit comments

Comments
 (0)