check for error list length and not existence

pull/1/head
Liana Husikyan 5 years ago committed by GitHub
parent 372ed0224c
commit 2def63cc99
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      src/app/tabs/compile-tab.js

@ -114,7 +114,7 @@ class CompileTab extends ViewPlugin {
if (success) { if (success) {
// forwarding the event to the appManager infra // forwarding the event to the appManager infra
this.emit('compilationFinished', source.target, source, 'soljson', data) this.emit('compilationFinished', source.target, source, 'soljson', data)
if (data.errors) { if (data.errors && data.errors.length > 0) {
this.emit('statusChanged', { this.emit('statusChanged', {
key: data.errors.length, key: data.errors.length,
title: `compilation finished successful with warning${data.errors.length > 1 ? 's' : ''}`, title: `compilation finished successful with warning${data.errors.length > 1 ? 's' : ''}`,

Loading…
Cancel
Save