-
Notifications
You must be signed in to change notification settings - Fork 315
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #7019 from LedgerHQ/bugfix/LIVE-12325-remove-manag…
…er-v1-api-calls [LIVE-12325] Remove remaining manager v1 api calls (outside of list apps v1)
- Loading branch information
Showing
24 changed files
with
186 additions
and
237 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
"@ledgerhq/device-core": patch | ||
"@ledgerhq/live-common": patch | ||
--- | ||
|
||
Create getAppsCatalogForDevice use case |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
--- | ||
"ledger-live-desktop": patch | ||
"live-mobile": patch | ||
"@ledgerhq/live-common": patch | ||
--- | ||
|
||
Refactor "app update available" logic to only rely on v2 manager apis |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
--- | ||
"@ledgerhq/live-cli": patch | ||
"@ledgerhq/web-tools": patch | ||
--- | ||
|
||
Refactor install/uninstall app commands to only rely on v2 manager apis |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
apps/ledger-live-desktop/src/renderer/screens/settings/sections/General/LanguageSelect.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
apps/ledger-live-mobile/src/screens/SyncOnboarding/LanguagePrompt.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 8 additions & 35 deletions
43
apps/web-tools/repl/components/fields/ApplicationField.tsx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
19 changes: 19 additions & 0 deletions
19
libs/device-core/src/managerApi/use-cases/getAppsCatalogForDevice.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
import { ManagerApiRepository } from "../repositories/ManagerApiRepository"; | ||
|
||
type Params = { | ||
firmwareVersion: string; | ||
targetId: string | number; | ||
provider: number; | ||
}; | ||
|
||
export async function getAppsCatalogForDevice( | ||
params: Params, | ||
managerApiRepository: ManagerApiRepository, | ||
) { | ||
const { firmwareVersion, targetId, provider } = params; | ||
return managerApiRepository.catalogForDevice({ | ||
firmwareVersion, | ||
provider, | ||
targetId, | ||
}); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
16 changes: 16 additions & 0 deletions
16
libs/ledger-live-common/src/device/use-cases/getAppsCatalogForDevice.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { | ||
ManagerApiRepository, | ||
getAppsCatalogForDevice as coreGetAppsCatalogForDevice, | ||
} from "@ledgerhq/device-core"; | ||
import { HttpManagerApiRepositoryFactory } from "../factories/HttpManagerApiRepositoryFactory"; | ||
import { getProviderId } from "../../manager"; | ||
import { DeviceInfo } from "@ledgerhq/types-live"; | ||
|
||
export function getAppsCatalogForDevice( | ||
deviceInfo: DeviceInfo, | ||
managerApiRepository: ManagerApiRepository = HttpManagerApiRepositoryFactory.getInstance(), | ||
) { | ||
const { version: firmwareVersion, targetId } = deviceInfo; | ||
const provider = getProviderId(deviceInfo); | ||
return coreGetAppsCatalogForDevice({ firmwareVersion, targetId, provider }, managerApiRepository); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.