mirror of
https://github.com/redphx/better-xcloud.git
synced 2025-08-10 07:07:46 +02:00
Linting
This commit is contained in:
@@ -55,11 +55,11 @@ export class BaseLocalTable<T extends BaseRecord> {
|
||||
return this.call(table.get.bind(table), ...arguments);
|
||||
}
|
||||
|
||||
async getAll(): Promise<{[key: string]: T}> {
|
||||
async getAll(): Promise<{ [key: string]: T }> {
|
||||
const table = await this.prepareTable();
|
||||
// @ts-ignore
|
||||
const all = await (this.call(table.getAll.bind(table), ...arguments) as Promise<T[]>);
|
||||
const results: {[key: string]: T} = {};
|
||||
const results: { [key: string]: T } = {};
|
||||
|
||||
all.forEach(item => {
|
||||
results[item.id as T['id']] = item;
|
||||
|
@@ -23,9 +23,13 @@ export class ControllerSettingsTable extends BaseLocalTable<ControllerSettingsRe
|
||||
|
||||
async getControllersData() {
|
||||
const all = await this.getAll();
|
||||
const results: {[key: string]: ControllerSettingsRecord['data']} = {};
|
||||
const results: { [key: string]: ControllerSettingsRecord['data'] } = {};
|
||||
|
||||
for (const key in all) {
|
||||
if (!all[key]) {
|
||||
continue;
|
||||
}
|
||||
|
||||
const settings = all[key].data;
|
||||
// Pre-calculate virabtionIntensity
|
||||
settings.vibrationIntensity /= 100;
|
||||
|
Reference in New Issue
Block a user