support for 3rd party server urls

This commit is contained in:
Justin Mitchell
2026-01-04 23:02:48 -05:00
parent d75d911c1b
commit ae34fc76e1
4 changed files with 75 additions and 12 deletions

View File

@@ -11,6 +11,7 @@ class KOReaderCredentialStore {
static KOReaderCredentialStore instance;
std::string username;
std::string password;
std::string serverUrl; // Custom sync server URL (empty = default)
// Private constructor for singleton
KOReaderCredentialStore() = default;
@@ -43,6 +44,13 @@ class KOReaderCredentialStore {
// Clear credentials
void clearCredentials();
// Server URL management
void setServerUrl(const std::string& url);
const std::string& getServerUrl() const { return serverUrl; }
// Get base URL for API calls (with https:// normalization, falls back to default)
std::string getBaseUrl() const;
};
// Helper macro to access credential store