File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed
spec/lib/repo_host/bitbucket Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -97,9 +97,7 @@ def head_commit_message
97
97
98
98
# ✔️
99
99
def commit_author
100
- if @commits . present? && @commits . last . present?
101
- @commits . last [ "author" ] [ "user" ] [ "nickname" ]
102
- end
100
+ @commits . last &.dig ( "author" , "user" , "nickname" ) || ""
103
101
end
104
102
105
103
# ✔️
Original file line number Diff line number Diff line change @@ -115,6 +115,9 @@ def build_payload(string)
115
115
expect ( payload_for_branch_deletion . author_email ) . to eq ""
116
116
expect ( payload_for_new_branch_with_new_commits . author_email ) . to eq ""
117
117
expect ( payload_for_new_branch_without_new_commits . author_email ) . to eq ""
118
+ expect ( payload_for_branch_deletion . commit_author ) . to eq ""
119
+ expect ( payload_for_new_branch_with_new_commits . commit_author ) . to eq "milana_stojadinov"
120
+ expect ( payload_for_new_branch_without_new_commits . commit_author ) . to eq "milana_stojadinov"
118
121
end
119
122
end
120
123
You can’t perform that action at this time.
0 commit comments