Merge pull request #134 from coollabsio/next

fix: Error with follow logs
This commit is contained in:
Andras Bacsai 2022-02-15 10:59:58 +01:00 committed by GitHub
commit 86918f5160
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -57,15 +57,12 @@
logs = logs.concat(data.logs.map((log) => ({ ...log, line: cleanAnsiCodes(log.line) }))); logs = logs.concat(data.logs.map((log) => ({ ...log, line: cleanAnsiCodes(log.line) })));
dispatch('updateBuildStatus', { status }); dispatch('updateBuildStatus', { status });
if (followingBuild) {
const logEl = document.getElementById('logs');
logEl.scrollTop = logEl.scrollHeight;
}
} catch ({ error }) { } catch ({ error }) {
return errorNotification(error); return errorNotification(error);
} }
}, 1000); }, 1000);
} catch ({ error }) { } catch ({ error }) {
console.log(error);
return errorNotification(error); return errorNotification(error);
} }
} }