Fix Comments and provide proper english

This commit is contained in:
Maroxy 2021-12-21 22:45:01 +01:00
parent 748b197984
commit fe3cff78ad
No known key found for this signature in database
GPG key ID: F4B27EADB21E3021
6 changed files with 23 additions and 23 deletions

View file

@ -92,7 +92,7 @@ export default abstract class Installer
} }
/** /**
* Specify event that will be called after downloading will begin * Specify event that will be called after download has begun
* *
* @param callback * @param callback
*/ */
@ -105,7 +105,7 @@ export default abstract class Installer
} }
/** /**
* Specify event that will be called after unpacking will begin * Specify event that will be called after extraction has begun
* *
* @param callback * @param callback
*/ */
@ -118,7 +118,7 @@ export default abstract class Installer
} }
/** /**
* Specify event that will be called every [this.downloadProgressInterval] ms during downloading * Specify event that will be called every [this.downloadProgressInterval] ms while downloading
* *
* @param callback * @param callback
*/ */
@ -128,7 +128,7 @@ export default abstract class Installer
} }
/** /**
* Specify event that will be called every [this.unpackProgressInterval] ms during unpacking * Specify event that will be called every [this.unpackProgressInterval] ms while extracting
* *
* @param callback * @param callback
*/ */
@ -138,7 +138,7 @@ export default abstract class Installer
} }
/** /**
* Specify event that will be called after downloading will be finished * Specify event that will be called after download has finished
* *
* @param callback * @param callback
*/ */
@ -151,7 +151,7 @@ export default abstract class Installer
} }
/** /**
* Specify event that will be called after unpacking will be finished * Specify event that will be called after extraction has finished
* *
* @param callback * @param callback
*/ */

View file

@ -109,7 +109,7 @@ class Stream
} }
/** /**
* Specify event that will be called when the unpacking will be started * Specify event that will be called when the extraction has started
* *
* @param callback * @param callback
*/ */
@ -122,7 +122,7 @@ class Stream
} }
/** /**
* Specify event that will be called every [this.progressInterval] ms during archive unpacking * Specify event that will be called every [this.progressInterval] ms while extracting the archive
* *
* @param callback * @param callback
*/ */
@ -132,7 +132,7 @@ class Stream
} }
/** /**
* Specify event that will be called after the archive will be unpacked * Specify event that will be called after the archive has been extracted
* *
* @param callback * @param callback
*/ */
@ -145,7 +145,7 @@ class Stream
} }
/** /**
* Specify event that will be called if archive can't be unpacked * Specify event that will be called if archive can't be extracted
* *
* @param callback * @param callback
*/ */

View file

@ -13,7 +13,7 @@ export default class Configs
* Get config value * Get config value
* *
* @param name config name, e.g. "lang.launcher" * @param name config name, e.g. "lang.launcher"
* @returns undefined if config is not exists. Otherwise - config value * @returns undefined if config doesn't exist. Otherwise - config value
*/ */
public static get(name: string = ''): Promise<undefined|scalar|scalar[]> public static get(name: string = ''): Promise<undefined|scalar|scalar[]>
{ {
@ -38,7 +38,7 @@ export default class Configs
* *
* @param name config name, e.g. "lang.launcher" * @param name config name, e.g. "lang.launcher"
* @param value config value, e.g. "en-us" * @param value config value, e.g. "en-us"
* @returns Promise<void> indicates when the settings was updated * @returns Promise<void> indicates if the settings were updated
*/ */
public static set(name: string, value: scalar|scalar[]): Promise<void> public static set(name: string, value: scalar|scalar[]): Promise<void>
{ {
@ -68,7 +68,7 @@ export default class Configs
* Set default values * Set default values
* *
* @param configs object of default values * @param configs object of default values
* @returns Promise<void> indicates when the default settings was applied * @returns Promise<void> indicates if the default settings were applied
*/ */
public static defaults(configs: scalar): Promise<void> public static defaults(configs: scalar): Promise<void>
{ {
@ -76,7 +76,7 @@ export default class Configs
const setDefaults = async (current: scalar) => { const setDefaults = async (current: scalar) => {
const updateDefaults = (current: scalar, defaults: scalar) => { const updateDefaults = (current: scalar, defaults: scalar) => {
Object.keys(defaults).forEach((key) => { Object.keys(defaults).forEach((key) => {
// If the field exists in defaults and don't exists in current // If the field exists in defaults and doesn't exist in current
if (current[key] === undefined) if (current[key] === undefined)
current[key] = defaults[key]; current[key] = defaults[key];

View file

@ -50,13 +50,13 @@ export default class DXVK
* Download DXVK to the [Constants.paths.dxvks] directory * Download DXVK to the [Constants.paths.dxvks] directory
* *
* @param dxvk DXVK object or version * @param dxvk DXVK object or version
* @returns null if the DXVK with specified version is not exists. Otherwise - installation stream * @returns null if the DXVK with specified version dosen't exist. Otherwise - installation stream
*/ */
public static download(dxvk: TDXVK|TDXVK['version']): Promise<null|Stream> public static download(dxvk: TDXVK|TDXVK['version']): Promise<null|Stream>
{ {
return new Promise(async (resolve) => { return new Promise(async (resolve) => {
// If we provided dxvk property as a version of the DXVK // If we provided dxvk parameter with a version of DXVK
// then we should find this DXVK and call this method from it // then we should find this DXVK version and call this method for it
if (typeof dxvk == 'string') if (typeof dxvk == 'string')
{ {
let foundDXVK = null; let foundDXVK = null;

View file

@ -59,7 +59,7 @@ class Stream
} }
/** /**
* Specify event that will be called when the downloading will be started * Specify event that will be called when the download gets started
* *
* @param callback * @param callback
*/ */
@ -72,7 +72,7 @@ class Stream
} }
/** /**
* Specify event that will be called every [this.progressInterval] ms during the file downloading * Specify event that will be called every [this.progressInterval] ms while the file is downloading
* *
* @param callback * @param callback
*/ */
@ -82,7 +82,7 @@ class Stream
} }
/** /**
* Specify event that will be called after the file will be downloaded * Specify event that will be called after the file is downloaded
* *
* @param callback * @param callback
*/ */

View file

@ -62,13 +62,13 @@ class Runners
* Download runner to the [Constants.paths.runners] directory * Download runner to the [Constants.paths.runners] directory
* *
* @param runner runner object or name * @param runner runner object or name
* @returns null if the runner with specified name is not exists. Otherwise - installation stream * @returns null if the runner with specified name dosen't exist. Otherwise - installation stream
*/ */
public static download(runner: Runner|Runner['name']): Promise<null|Stream> public static download(runner: Runner|Runner['name']): Promise<null|Stream>
{ {
return new Promise(async (resolve) => { return new Promise(async (resolve) => {
// If we provided runner property as a name of the runner // If we provided runner parameter with a name of a runner
// then we should find this runner and call this method from it // then we should find this runner and call this method for it
if (typeof runner == 'string') if (typeof runner == 'string')
{ {
let foundRunner = null; let foundRunner = null;