Changeset 7064 for sites/trunk/svn.wordpress.org/bin/slack-trac-hook.php
- Timestamp:
- 04/08/2018 11:43:27 AM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sites/trunk/svn.wordpress.org/bin/slack-trac-hook.php
r3062 r7064 24 24 $ticket_base_url = $matches[3]; 25 25 $ticket = $matches[4]; 26 $type = isset( $matches[5] ) ? 'comment' : 'ticket'; 26 // Attachment notifcations use the ticket URL, check for attachment change line and process mail as comment on match. 27 $is_attachment = (bool) preg_grep( '/^ \* Attachment "([^"]+)"/', $lines ); 28 $type = ( isset( $matches[5] ) || $is_attachment ) ? 'comment' : 'ticket'; 27 29 preg_match( '~^https?://([^.]+)\.trac~i', $ticket_base_url, $matches ); 28 30 $trac = $matches[1];
Note: See TracChangeset
for help on using the changeset viewer.