File tree 2 files changed +5
-4
lines changed 2 files changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -221,7 +221,7 @@ impl Info {
221
221
let number_of_branches = internal_repo. get_number_of_branches ( ) ?;
222
222
let creation_date = internal_repo. get_creation_date ( config. iso_time ) ?;
223
223
let number_of_commits = internal_repo. get_number_of_commits ( ) ;
224
- let authors = internal_repo. get_authors ( config. number_of_authors , config. show_email ) ;
224
+ let authors = internal_repo. get_authors ( config. number_of_authors , config. show_email ) ? ;
225
225
let last_change = internal_repo. get_date_of_last_commit ( config. iso_time ) ;
226
226
let ( repo_size, file_count) = internal_repo. get_repo_size ( ) ;
227
227
let workdir = internal_repo. get_work_dir ( ) ?;
Original file line number Diff line number Diff line change @@ -67,12 +67,13 @@ impl<'a> Repo<'a> {
67
67
& self ,
68
68
n : usize ,
69
69
show_email : bool ,
70
- ) -> Vec < ( String , Option < String > , usize , usize ) > {
70
+ ) -> Result < Vec < ( String , Option < String > , usize , usize ) > > {
71
71
let mut authors = std:: collections:: HashMap :: new ( ) ;
72
72
let mut author_name_by_email = std:: collections:: HashMap :: new ( ) ;
73
73
let mut total_nbr_of_commits = 0 ;
74
+ let mailmap = self . repo . mailmap ( ) ?;
74
75
for commit in & self . logs {
75
- let author = commit. author ( ) ;
76
+ let author = commit. author_with_mailmap ( & mailmap ) ? ;
76
77
let author_name = String :: from_utf8_lossy ( author. name_bytes ( ) ) . into_owned ( ) ;
77
78
let author_email = String :: from_utf8_lossy ( author. email_bytes ( ) ) . into_owned ( ) ;
78
79
@@ -100,7 +101,7 @@ impl<'a> Repo<'a> {
100
101
} )
101
102
. collect ( ) ;
102
103
103
- authors
104
+ Ok ( authors)
104
105
}
105
106
106
107
pub fn get_date_of_last_commit ( & self , iso_time : bool ) -> String {
You can’t perform that action at this time.
0 commit comments