Skip to content

Commit

Permalink
update code formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
Thomas Bowman Mørch committed Mar 17, 2019
1 parent e5e646d commit a52d3dd
Show file tree
Hide file tree
Showing 13 changed files with 21 additions and 24 deletions.
2 changes: 2 additions & 0 deletions src/lib/database-sqlite.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
import * as path from 'path';
import { open } from 'sqlite';

import { IDatabase, INodeData, ISensorData } from './database.interface';
import { NullCheck } from './nullcheck';

export class DatabaseSqlite implements IDatabase {
private dbPromise: any;

Expand Down
2 changes: 1 addition & 1 deletion src/lib/database.interface.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import { mysensor_sensor } from './mysensors-types';

export interface INodeData {
id: number;
nodeId: number;
label: string;
sketchName: string;
sketchVersion: string;
Expand Down
1 change: 1 addition & 0 deletions src/lib/mysensors-controller.spec.ts
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import { expect } from 'chai';
import { IDatabase } from 'node-red-contrib-mysensors/src/lib/database.interface';
import * as sinon from 'sinon';

import { DatabaseSqlite } from './database-sqlite';
import { MysensorsController } from './mysensors-controller';
import { IMysensorsMsg } from './mysensors-msg';
Expand Down
1 change: 1 addition & 0 deletions src/lib/mysensors-controller.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import * as moment from 'moment-timezone';

import { IDatabase } from './database.interface';
import { AutoDecode } from './decoder/auto-decode';
import { IDecoder } from './decoder/decoder.interface';
Expand Down
10 changes: 3 additions & 7 deletions src/lib/mysensors-debug.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,7 @@
import {
mysensor_command,
mysensor_data,
mysensor_internal,
mysensor_payload,
mysensor_sensor,
mysensor_stream,
} from './mysensors-types';
mysensor_command, mysensor_data, mysensor_internal, mysensor_payload, mysensor_sensor,
mysensor_stream
} from './mysensors-types';

/* tslint:disable:max-line-length */

Expand Down
8 changes: 3 additions & 5 deletions src/lib/mysensors-msg.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,6 @@
import { mysensor_command } from './mysensors-types';
import { mysensor_data } from './mysensors-types';
import { mysensor_internal } from './mysensors-types';
import { mysensor_sensor } from './mysensors-types';
import { mysensor_stream } from './mysensors-types';
import {
mysensor_command, mysensor_data, mysensor_internal, mysensor_sensor, mysensor_stream
} from './mysensors-types';

export interface INodeMessage {
payload: string;
Expand Down
1 change: 1 addition & 0 deletions src/nodes/common.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { Node, NodeId, NodeProperties } from 'node-red';

import { IDatabase } from '../lib/database.interface';
import { IDecoder } from '../lib/decoder/decoder.interface';
import { MysensorsController } from '../lib/mysensors-controller';
Expand Down
1 change: 1 addition & 0 deletions src/nodes/controller.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { Red } from 'node-red';

import { MysensorsController } from '../lib/mysensors-controller';
import { IMysensorsMsg } from '../lib/mysensors-msg';
import { IControllerConfig, IControllerProperties, IDbConfigNode } from './common';
Expand Down
1 change: 1 addition & 0 deletions src/nodes/decode.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { Red } from 'node-red';

import { MysensorsMqtt } from '../lib/decoder/mysensors-mqtt';
import { MysensorsSerial } from '../lib/decoder/mysensors-serial';
import { IMysensorsMsg } from '../lib/mysensors-msg';
Expand Down
7 changes: 2 additions & 5 deletions src/nodes/encapsulate.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
import { NodeProperties, Red } from 'node-red';

import { IMysensorsMsg } from '../lib/mysensors-msg';
import {
mysensor_data,
mysensor_internal,
mysensor_sensor,
} from '../lib/mysensors-types';
import { mysensor_data, mysensor_internal, mysensor_sensor } from '../lib/mysensors-types';
import { IEncapsulateConfig, IEncapsulateProperties } from './common';

export = (RED: Red) => {
Expand Down
1 change: 1 addition & 0 deletions src/nodes/encode.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { NodeProperties, Red } from 'node-red';

import { MysensorsMqtt } from '../lib/decoder/mysensors-mqtt';
import { MysensorsSerial } from '../lib/decoder/mysensors-serial';
import { IMysensorsMsg } from '../lib/mysensors-msg';
Expand Down
9 changes: 3 additions & 6 deletions src/nodes/mysdebug.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,11 @@
import { NodeProperties, Red } from 'node-red';

import { AutoDecode } from '../lib/decoder/auto-decode';
import { MysensorsDebugDecode } from '../lib/mysensors-debug';
import { IMysensorsMsg } from '../lib/mysensors-msg';
import {
mysensor_command,
mysensor_data,
mysensor_internal,
mysensor_sensor,
mysensor_stream,
} from '../lib/mysensors-types';
mysensor_command, mysensor_data, mysensor_internal, mysensor_sensor, mysensor_stream
} from '../lib/mysensors-types';
import { NullCheck } from '../lib/nullcheck';
import { IDebugConfig } from './common';

Expand Down
1 change: 1 addition & 0 deletions src/nodes/mysensors-db.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { NodeProperties, Red } from 'node-red';
import { resolve } from 'path';

import { DatabaseSqlite } from '../lib/database-sqlite';
import { IDbConfigNode, IDBProperties } from './common';

Expand Down

0 comments on commit a52d3dd

Please sign in to comment.