Merge pull request #2148 from szeck87/error-message-patch1
Fix to show executable error instead of Docker
This commit is contained in:
commit
f4ca817c16
|
@ -1,4 +1,5 @@
|
|||
# Next
|
||||
- Fixes an issue where Atom Beautify would display a Docker error instead of an executable error ([#2146](https://github.com/Glavin001/atom-beautify/issues/2146))
|
||||
|
||||
# v0.32.5 (2018-05-28)
|
||||
- Fixes an issue with Rubocop not working on Windows ([#2092](https://github.com/Glavin001/atom-beautify/issues/2092))
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
[![GitHub issues](https://img.shields.io/github/issues/Glavin001/atom-beautify.svg?style=flat-square)](https://github.com/Glavin001/atom-beautify/issues)
|
||||
[![Greenkeeper badge](https://badges.greenkeeper.io/Glavin001/atom-beautify.svg)](https://greenkeeper.io/)
|
||||
|
||||
[![Slack](https://unibeautify-slack.herokuapp.com/badge.svg)](https://unibeautify-slack.herokuapp.com/)
|
||||
[![Slack](https://unibeautify-slack.glitch.me/badge.svg)](https://unibeautify-slack.glitch.me/)
|
||||
[![Twitter Follow](https://img.shields.io/twitter/follow/unibeautify.svg?style=social&label=Follow)](https://twitter.com/unibeautify)
|
||||
[![Gitter](https://img.shields.io/gitter/room/Glavin001/atom-beautify.svg?style=flat-square)](https://gitter.im/Glavin001/atom-beautify)
|
||||
[![Bountysource](https://img.shields.io/bountysource/team/atom-beautify/activity.svg?style=flat-square)](https://www.bountysource.com/teams/atom-beautify)
|
||||
|
|
|
@ -394,13 +394,13 @@ class HybridExecutable extends Executable
|
|||
)
|
||||
.catch((error) =>
|
||||
return Promise.reject(error) if not @docker?
|
||||
return @
|
||||
return Promise.resolve(error)
|
||||
)
|
||||
.then(() =>
|
||||
.then((errorOrThis) =>
|
||||
shouldTryWithDocker = not @isInstalled and @docker?
|
||||
@verbose("Executable shouldTryWithDocker", shouldTryWithDocker, @isInstalled, @docker?)
|
||||
if shouldTryWithDocker
|
||||
return @initDocker()
|
||||
return @initDocker().catch(() => Promise.reject(errorOrThis))
|
||||
return @
|
||||
)
|
||||
.catch((error) =>
|
||||
|
@ -460,5 +460,4 @@ class HybridExecutable extends Executable
|
|||
)
|
||||
)
|
||||
|
||||
|
||||
module.exports = HybridExecutable
|
||||
|
|
Loading…
Reference in New Issue