File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed
themes/contribute.jquery.org Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -133,12 +133,15 @@ function neglectedAuthors( $data ) {
133
133
}
134
134
135
135
function commitLog ( $ data ) {
136
- $ commitPrefix = "https://github.com/ $ data ->owner / $ data ->repo /commit/ " ;
136
+ $ commitPrefix = "https://github.com/ " .
137
+ htmlspecialchars ( "$ data ->owner / $ data ->repo " ) .
138
+ "/commit/ " ;
137
139
138
140
$ html = "<dl> \n" ;
139
141
foreach ( $ data ->data ->commits as $ commit ) {
140
- $ html .= "<dt><a href=' $ commitPrefix$ commit ->hash '> $ commit ->hash </a></dt> \n" ;
141
- $ html .= "<dd> " . htmlspecialchars ( "$ commit ->name < $ commit ->email > " ) . "</dd \n" ;
142
+ $ escapedHash = htmlspecialchars ( $ commit ->hash );
143
+ $ html .= "<dt><a href= \"$ commitPrefix$ escapedHash \"> $ escapedHash</a></dt> \n" ;
144
+ $ html .= "<dd> " . htmlspecialchars ( "$ commit ->name < $ commit ->email > " ) . "</dd> \n" ;
142
145
}
143
146
$ html .= "</dl> \n" ;
144
147
return $ html ;
You can’t perform that action at this time.
0 commit comments