From: <gi...@ma...> - 2009-09-04 14:02:43
|
The branch, master-1.2.x has been updated via fa252970293073146d6378147e46cc1b3b0181f8 (commit) from 7f8b2028f8996c451636880e122fb48ec1911ccb (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit fa252970293073146d6378147e46cc1b3b0181f8 Author: Chris Fitch <cf...@re...> Date: Fri Sep 4 08:56:31 2009 -0400 Issue 10905: Move BUGNOTE_ADD event to bugnote_add() function The BUGNOTE_ADD event is only sent when a bugnote is added from the view page. Moving it from bugnote_add.php to the bugnote_add() function in core/bugnote_api.php will ensure that it is sent from the edit page as well. Signed-off-by: David Hicks <hic...@op...> ----------------------------------------------------------------------- Summary of changes: bugnote_add.php | 3 --- core/bugnote_api.php | 3 +++ 2 files changed, 3 insertions(+), 3 deletions(-) ----------------------------------------------------------------------- commit fa252970293073146d6378147e46cc1b3b0181f8 Author: Chris Fitch <cf...@re...> Date: Fri Sep 4 08:56:31 2009 -0400 Issue 10905: Move BUGNOTE_ADD event to bugnote_add() function The BUGNOTE_ADD event is only sent when a bugnote is added from the view page. Moving it from bugnote_add.php to the bugnote_add() function in core/bugnote_api.php will ensure that it is sent from the edit page as well. Signed-off-by: David Hicks <hic...@op...> diff --git a/bugnote_add.php b/bugnote_add.php index d579232..ba8be0e 100644 --- a/bugnote_add.php +++ b/bugnote_add.php @@ -59,9 +59,6 @@ trigger_error( ERROR_EMPTY_FIELD, ERROR ); } - # Event integration - event_signal( 'EVENT_BUGNOTE_ADD', array( $f_bug_id, $t_bugnote_id ) ); - form_security_purge( 'bugnote_add' ); print_successful_redirect_to_bug( $f_bug_id ); diff --git a/core/bugnote_api.php b/core/bugnote_api.php index 3f0f0c9..ebc70b4 100644 --- a/core/bugnote_api.php +++ b/core/bugnote_api.php @@ -183,6 +183,9 @@ function bugnote_add( $p_bug_id, $p_bugnote_text, $p_time_tracking = '0:00', $p_ # log new bug history_log_event_special( $p_bug_id, BUGNOTE_ADDED, bugnote_format_id( $t_bugnote_id ) ); + # Event integration + event_signal( 'EVENT_BUGNOTE_ADD', array( $p_bug_id, $t_bugnote_id ) ); + # only send email if the text is not blank, otherwise, it is just recording of time without a comment. if( TRUE == $p_send_email && !is_blank( $p_bugnote_text ) ) { email_bugnote_add( $p_bug_id ); ----------------------------------------------------------------------- -- Mantis Bug Tracker |