-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: configuration update with organization name (#217)
- move organizationName property to the CrowdinConfig with backward compatibility; - deprecate usage in AuthConfig; - add new check in config builder for organization name when hash matches enterprise project; - documentation update;
- Loading branch information
1 parent
7f498c5
commit 744634b
Showing
19 changed files
with
80 additions
and
31 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
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
24 changes: 22 additions & 2 deletions
24
crowdin/src/main/java/com/crowdin/platform/data/model/AuthConfig.kt
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 |
---|---|---|
@@ -1,8 +1,28 @@ | ||
package com.crowdin.platform.data.model | ||
|
||
data class AuthConfig( | ||
data class AuthConfig @Deprecated( | ||
"Use constructor without organizationName instead. organizationName is now part of the `CrowdinConfig` " + | ||
"and should be provided with this method: `.withOrganizationName(organizationName)`", | ||
replaceWith = ReplaceWith("AuthConfig(clientId, clientSecret, requestAuthDialog)") | ||
) constructor( | ||
val clientId: String, | ||
val clientSecret: String, | ||
@Deprecated("Use CrowdinConfig property instead") | ||
val organizationName: String? = null, | ||
val requestAuthDialog: Boolean = true | ||
) | ||
) { | ||
|
||
constructor(clientId: String, clientSecret: String) : this( | ||
clientId = clientId, | ||
clientSecret = clientSecret, | ||
organizationName = null, | ||
requestAuthDialog = true | ||
) | ||
|
||
constructor(clientId: String, clientSecret: String, requestAuthDialog: Boolean) : this( | ||
clientId = clientId, | ||
clientSecret = clientSecret, | ||
organizationName = null, | ||
requestAuthDialog = requestAuthDialog | ||
) | ||
} |
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
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
Oops, something went wrong.