From 47630b5bab73beace33475da5aec8280b465ab70 Mon Sep 17 00:00:00 2001 From: Piotr Sarnacki Date: Wed, 8 May 2013 01:24:29 +0200 Subject: [PATCH] Use view.jobIdForLog instead of showDownloadLog The latter is not always refreshed, I don't have time to debug it more thoroughly --- assets/scripts/app/templates/repos/show/tools.hbs | 4 +++- assets/scripts/lib/travis/ajax.coffee | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/assets/scripts/app/templates/repos/show/tools.hbs b/assets/scripts/app/templates/repos/show/tools.hbs index 4e2b77c2..7ba1c0d4 100644 --- a/assets/scripts/app/templates/repos/show/tools.hbs +++ b/assets/scripts/app/templates/repos/show/tools.hbs @@ -37,7 +37,9 @@ {{/if}} - {{#if view.showDownloadLog}} + {{!TODO: for some reason showDownloadLog, which just delegates to jobIdForLog + does not refresh 'if' properly, need further investigation}} + {{#if view.jobIdForLog}}
  • Download log
  • diff --git a/assets/scripts/lib/travis/ajax.coffee b/assets/scripts/lib/travis/ajax.coffee index efa27009..357aebfa 100644 --- a/assets/scripts/lib/travis/ajax.coffee +++ b/assets/scripts/lib/travis/ajax.coffee @@ -76,7 +76,7 @@ Travis.ajax = Em.Object.create xhr.open(method, url) - if options.accepts + if options.accepts && !options.headers?.accept? accepts = [] for key, value of options.accepts accepts.pushObject(value)