Skip to content

Commit 9061719

Browse files
committed
eslint
1 parent f53ff2c commit 9061719

File tree

3 files changed

+6
-6
lines changed

3 files changed

+6
-6
lines changed

bundles/paikkatietoikkuna/coordinatetransformation/handler/FileParser.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { SRS, DEGREE, HOUR_TO_MIN, HOUR_TO_SEC, DEC_TO_GRAD, DEC_TO_RAD } from '../constants';
1+
import { SRS, DEGREE, HOUR_TO_MIN, HOUR_TO_SEC, DEC_TO_GRAD, DEC_TO_RAD } from '../constants';
22

33
export const parseFile = (file) => {
44
return new Promise((resolve, reject) => {
@@ -23,7 +23,7 @@ const addToArray = (array, index, value) => {
2323

2424
export const parseFileContents = (lines = [], delimiter = ';', headerLineCount = 0, prefixColCount = 0) => {
2525
// parse always x,y,z to data
26-
const dimension = 3; //TODO: data[2] or z could contain lineEnding stuff for 2D
26+
const dimension = 3; // TODO: data[2] or z could contain lineEnding stuff for 2D
2727
const headerMetadata = {
2828
headerLines: [],
2929
headers: []
@@ -173,6 +173,7 @@ const detectEpsgCode = (headerLine) => {
173173
return codes.find(code => SRS.find(s => s.value === code));
174174
};
175175

176+
// eslint-disable-next-line no-unused-vars
176177
const isNumericRow = (row, delimiter) => {
177178
const cells = row.split(delimiter).map(cell => cell.trim());
178179

bundles/paikkatietoikkuna/coordinatetransformation/handler/ViewHandler.js

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -433,7 +433,7 @@ class UIHandler extends StateHandler {
433433
const { headerLineCount, ...restSettings } = state.fileContents.settings;
434434
const writeHeaders = headerLineCount > 0;
435435
// use default values from import file
436-
this.updateState({ export: { ...state.export, ...restSettings, writeHeaders }});
436+
this.updateState({ export: { ...state.export, ...restSettings, writeHeaders } });
437437
}
438438
this.filePopup = showFilePopup(type, this.getState(), this.getController(), () => this.closeFileSettings());
439439
}
@@ -532,7 +532,6 @@ class UIHandler extends StateHandler {
532532
Object.keys(info).forEach(key => this.log.debug(key, '=>', info[key]));
533533
}
534534

535-
536535
importFileContentsToInputTable () {
537536
const errors = validateFileSettings(this.getState(), 'import');
538537
if (errors.length) {

bundles/paikkatietoikkuna/coordinatetransformation/helper.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -242,8 +242,8 @@ export const getCoordinatesExtent = (coordinates, srs) => {
242242
return {
243243
extent: [minX, minY, maxX, maxY],
244244
bbox: { left: minX, bottom: minY, right: maxX, top: maxY },
245-
min: { x: swap ? minY : minX, y: swap ? minX : minY},
246-
max: { x: swap ? maxY : maxX, y: swap ? maxX : maxY},
245+
min: { x: swap ? minY : minX, y: swap ? minX : minY },
246+
max: { x: swap ? maxY : maxX, y: swap ? maxX : maxY },
247247
wkt: `POLYGON ((${minX} ${minY}, ${maxX} ${minY}, ${maxX} ${maxY}, ${minX} ${maxY}, ${minX} ${minY}))`
248248
};
249249
// Oskari.getSandbox().postRequestByName('MapModulePlugin.AddFeaturesToMapRequest', [wkt, { layerId: 'komu', centerTo: true }]);

0 commit comments

Comments
 (0)