add build completed flag

This commit is contained in:
oleg 2015-05-21 22:04:38 +03:00
parent dcf029371d
commit b4d5e785bb
2 changed files with 4 additions and 2 deletions

View File

@ -68,6 +68,7 @@ Distributor.prototype._runNext = function(callback) {
{
endDate: Date.now(),
status: err ? 'error' : 'done',
completed: true,
error: err ? err.message : null
},
function(err, build) {
@ -135,7 +136,8 @@ Distributor.prototype.run = function(project, params, callback) {
project: project,
params: params,
createDate: Date.now(),
status: 'queued'
status: 'queued',
completed: false
}, this.slot());
},
function(err, build) {

View File

@ -30,7 +30,7 @@ define([
};
// create data resource for completed build
if (build.status === 'done' || build.status === 'error') {
if (build.completed) {
connect.resource('projects')
.sync('createBuildDataResource', function(err) {
if (err) throw err;