| 893 | } |
| 894 | |
| 895 | void Backend::fetchRemoteApps() |
| 896 | { |
| 897 | if (m_accountId.isEmpty()) { |
| 898 | return; |
| 899 | } |
| 900 | if (m_providerName != "gdrive" && m_providerName != "onedrive") { |
| 901 | fprintf(stderr, "[Backend] provider is not gdrive/onedrive, skipping\n"); |
| 902 | emit remoteAppsFetched(); |
| 903 | return; |
| 904 | } |
| 905 | |
| 906 | QString token = readAccessToken(); |
| 907 | if (token.isEmpty()) { |
| 908 | fprintf(stderr, "[Backend] No valid access token for remote listing\n"); |
| 909 | emit remoteAppsFetched(); |
| 910 | return; |
| 911 | } |
| 912 | |
| 913 | if (m_providerName == "gdrive") |
| 914 | fetchGoogleDriveApps(token); |
| 915 | else |
| 916 | fetchOneDriveApps(token); |
| 917 | } |
| 918 | |
| 919 | void Backend::refreshAndFetch() |
| 920 | { |
nothing calls this directly
no outgoing calls
no test coverage detected