Skip to content

Commit a4c0b61

Browse files
committed
fix: Signing buttons don't work on startup
A constructed Program is not compiled until update_on_read() is run via the run button or by selecting an example program. As a fix, run update_on_read() inside the Program constructor.
1 parent c0c3df1 commit a4c0b61

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/components/program_window/program_tab.rs

+4-2
Original file line numberDiff line numberDiff line change
@@ -39,12 +39,14 @@ fn main() {{
3939
key.serialize().as_hex()
4040
);
4141

42-
Self {
42+
let program = Self {
4343
text: create_rw_signal(text),
4444
cached_text: create_rw_signal("".to_string()),
4545
lazy_cmr: create_rw_signal(Err("".to_string())),
4646
lazy_satisfied: create_rw_signal(Err("".to_string())),
47-
}
47+
};
48+
program.update_on_read();
49+
program
4850
}
4951

5052
pub fn cmr(self) -> Result<simplicity::Cmr, String> {

0 commit comments

Comments
 (0)