Skip to content

Commit

Permalink
refactor(window): use string ref over as_str
Browse files Browse the repository at this point in the history
  • Loading branch information
FineFindus committed Jul 12, 2024
1 parent 02bf231 commit 7657123
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/window.rs
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ impl HieroglyphicWindow {
.downcast_ref::<gtk::StringObject>()
.expect("Object should be of type `StringObject`");
let symbol_item = SymbolItem::new(
detexify::Symbol::from_id(symbol_object.string().as_str())
detexify::Symbol::from_id(&symbol_object.string())
.expect("`symbol_object` should be a valid symbol id"),
);
symbol_item.upcast()
Expand Down

0 comments on commit 7657123

Please sign in to comment.