|
4 | 4 | * DS207: Consider shorter variations of null checks
|
5 | 5 | * Full docs: https://github.com/decaffeinate/decaffeinate/blob/master/docs/suggestions.md
|
6 | 6 | */
|
7 |
| -import { time } from './misc'; |
8 |
| -import externalTerminal from './connection/terminal'; |
| 7 | +import { time } from "./misc" |
| 8 | +import externalTerminal from "./connection/terminal" |
9 | 9 |
|
10 | 10 | export default {
|
11 |
| - IPC: require('./connection/ipc'), |
12 |
| - messages: require('./connection/messages'), |
13 |
| - client: require('./connection/client'), |
14 |
| - local: require('./connection/local'), |
15 |
| - terminal: require('./connection/terminal'), |
| 11 | + IPC: require("./connection/ipc"), |
| 12 | + messages: require("./connection/messages"), |
| 13 | + client: require("./connection/client"), |
| 14 | + local: require("./connection/local"), |
| 15 | + terminal: require("./connection/terminal"), |
16 | 16 |
|
17 | 17 | activate() {
|
18 |
| - this.messages.activate(); |
19 |
| - this.client.activate(); |
20 |
| - this.client.boot = () => this.boot(); |
21 |
| - this.local.activate(); |
22 |
| - return this.booting = false; |
| 18 | + this.messages.activate() |
| 19 | + this.client.activate() |
| 20 | + this.client.boot = () => this.boot() |
| 21 | + this.local.activate() |
| 22 | + return (this.booting = false) |
23 | 23 | },
|
24 | 24 |
|
25 | 25 | deactivate() {
|
26 |
| - return this.client.deactivate(); |
| 26 | + return this.client.deactivate() |
27 | 27 | },
|
28 | 28 |
|
29 | 29 | consumeInk(ink) {
|
30 |
| - this.IPC.consumeInk(ink); |
31 |
| - return this.ink = ink; |
| 30 | + this.IPC.consumeInk(ink) |
| 31 | + return (this.ink = ink) |
32 | 32 | },
|
33 | 33 |
|
34 | 34 | consumeGetServerConfig(getconf) {
|
35 |
| - return this.local.consumeGetServerConfig(getconf); |
| 35 | + return this.local.consumeGetServerConfig(getconf) |
36 | 36 | },
|
37 | 37 |
|
38 | 38 | consumeGetServerName(name) {
|
39 |
| - return this.local.consumeGetServerName(name); |
| 39 | + return this.local.consumeGetServerName(name) |
40 | 40 | },
|
41 | 41 |
|
42 | 42 | _boot(provider) {
|
43 | 43 | if (!this.client.isActive() && !this.booting) {
|
44 |
| - let p; |
45 |
| - this.booting = true; |
46 |
| - this.client.setBootMode(provider); |
47 |
| - if (provider === 'External Terminal') { |
48 |
| - p = externalTerminal.connectedRepl(); |
| 44 | + let p |
| 45 | + this.booting = true |
| 46 | + this.client.setBootMode(provider) |
| 47 | + if (provider === "External Terminal") { |
| 48 | + p = externalTerminal.connectedRepl() |
49 | 49 | } else {
|
50 |
| - p = this.local.start(provider); |
| 50 | + p = this.local.start(provider) |
51 | 51 | }
|
52 | 52 |
|
53 | 53 | if (this.ink != null) {
|
54 |
| - this.ink.Opener.allowRemoteFiles(provider === 'Remote'); |
| 54 | + this.ink.Opener.allowRemoteFiles(provider === "Remote") |
55 | 55 | }
|
56 | 56 | p.then(() => {
|
57 |
| - return this.booting = false; |
58 |
| - }); |
| 57 | + return (this.booting = false) |
| 58 | + }) |
59 | 59 | p.catch(() => {
|
60 |
| - return this.booting = false; |
61 |
| - }); |
62 |
| - return time("Julia Boot", this.client.import('ping')()); |
| 60 | + return (this.booting = false) |
| 61 | + }) |
| 62 | + return time("Julia Boot", this.client.import("ping")()) |
63 | 63 | }
|
64 | 64 | },
|
65 | 65 |
|
66 | 66 | bootRemote() {
|
67 |
| - return this._boot('Remote'); |
| 67 | + return this._boot("Remote") |
68 | 68 | },
|
69 | 69 |
|
70 | 70 | boot() {
|
71 |
| - return this._boot(atom.config.get('julia-client.juliaOptions.bootMode')); |
| 71 | + return this._boot(atom.config.get("julia-client.juliaOptions.bootMode")) |
72 | 72 | }
|
73 |
| -}; |
| 73 | +} |
0 commit comments