js: don't abort on issues created in a closed state
This commit is contained in:
parent
018a02ca2e
commit
d5e8db37a9
|
@ -253,10 +253,12 @@ function alter_issue_show_page() {
|
|||
|
||||
if ($('div.issue.closed').length) { /* on a closed issue */
|
||||
var last_activity_url = $('#history a[href*=activity]').last().attr('href');
|
||||
var date = new Date(last_activity_url.split('=')[1]);
|
||||
var today = new Date();
|
||||
if (today - date > (60 * 86400*1000)) { /* older than 60 days */
|
||||
$('div#content > div.contextual .icon-edit').hide();
|
||||
if (typeof last_activity_url !== 'undefined') {
|
||||
var date = new Date(last_activity_url.split('=')[1]);
|
||||
var today = new Date();
|
||||
if (today - date > (60 * 86400*1000)) { /* older than 60 days */
|
||||
$('div#content > div.contextual .icon-edit').hide();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue