[Refactor] (Huge Refactoring) ReceiveRoutes: change the way define endpoints, hooks and methods.
Remove 'multi language translation enable/disable' related methods that is no longer in use from quite ago.
This commit is contained in:
@@ -57,4 +57,12 @@ export const genNumArray = (count, start_from = 0) => {
|
||||
|
||||
export const genNumObjArray = (count, start_from = 0) => {
|
||||
return arrayToObject(genNumArray(count, start_from));
|
||||
};
|
||||
|
||||
// This is using for only AI models compute device list, currently. (CTranslate2, Whisper)
|
||||
export const transformToIndexedArray = (devices) => {
|
||||
return devices.reduce((result, device, index) => {
|
||||
result[index] = device;
|
||||
return result;
|
||||
}, {});
|
||||
};
|
||||
Reference in New Issue
Block a user