@@ -10,7 +10,6 @@ use crate::{
10
10
use anyhow:: Result ;
11
11
use asyncgit:: { sync, CWD } ;
12
12
use crossterm:: event:: { Event , KeyCode } ;
13
- use log:: error;
14
13
use strings:: commands;
15
14
use sync:: HookResult ;
16
15
use tui:: { backend:: Backend , layout:: Rect , Frame } ;
@@ -104,7 +103,7 @@ impl CommitComponent {
104
103
if let HookResult :: NotOk ( e) =
105
104
sync:: hooks_commit_msg ( CWD , & mut msg) ?
106
105
{
107
- error ! ( "commit-msg hook error: {}" , e) ;
106
+ log :: error!( "commit-msg hook error: {}" , e) ;
108
107
self . queue . borrow_mut ( ) . push_back (
109
108
InternalEvent :: ShowErrorMsg ( format ! (
110
109
"commit-msg hook error:\n {}" ,
@@ -115,7 +114,7 @@ impl CommitComponent {
115
114
}
116
115
117
116
if let Err ( e) = sync:: commit ( CWD , & msg) {
118
- error ! ( "commit error: {}" , & e) ;
117
+ log :: error!( "commit error: {}" , & e) ;
119
118
self . queue . borrow_mut ( ) . push_back (
120
119
InternalEvent :: ShowErrorMsg ( format ! (
121
120
"commit failed:\n {}" ,
@@ -126,7 +125,7 @@ impl CommitComponent {
126
125
}
127
126
128
127
if let HookResult :: NotOk ( e) = sync:: hooks_post_commit ( CWD ) ? {
129
- error ! ( "post-commit hook error: {}" , e) ;
128
+ log :: error!( "post-commit hook error: {}" , e) ;
130
129
self . queue . borrow_mut ( ) . push_back (
131
130
InternalEvent :: ShowErrorMsg ( format ! (
132
131
"post-commit hook error:\n {}" ,
0 commit comments