mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2025-12-21 01:41:31 +00:00
Remove Explorer.isPreferredCassandraAPI (#654)
Co-authored-by: Steve Faulkner <471400+southpolesteve@users.noreply.github.com>
This commit is contained in:
@@ -116,11 +116,6 @@ export default class Explorer {
|
||||
* Use userContext.apiType instead
|
||||
* */
|
||||
public defaultExperience: ko.Observable<string>;
|
||||
/**
|
||||
* @deprecated
|
||||
* Compare a string with userContext.apiType instead: userContext.apiType === "Cassandra"
|
||||
* */
|
||||
public isPreferredApiCassandra: ko.Computed<boolean>;
|
||||
/**
|
||||
* @deprecated
|
||||
* Compare a string with userContext.apiType instead: userContext.apiType === "Mongo"
|
||||
@@ -414,10 +409,6 @@ export default class Explorer {
|
||||
});
|
||||
});
|
||||
|
||||
this.isPreferredApiCassandra = ko.computed(() => {
|
||||
const defaultExperience = (this.defaultExperience && this.defaultExperience()) || "";
|
||||
return defaultExperience.toLowerCase() === Constants.DefaultAccountExperience.Cassandra.toLowerCase();
|
||||
});
|
||||
this.isPreferredApiGraph = ko.computed(() => {
|
||||
const defaultExperience = (this.defaultExperience && this.defaultExperience()) || "";
|
||||
return defaultExperience.toLowerCase() === Constants.DefaultAccountExperience.Graph.toLowerCase();
|
||||
@@ -2097,7 +2088,7 @@ export default class Explorer {
|
||||
}
|
||||
|
||||
public onNewCollectionClicked(): void {
|
||||
if (this.isPreferredApiCassandra()) {
|
||||
if (userContext.apiType === "Cassandra") {
|
||||
this.cassandraAddCollectionPane.open();
|
||||
} else if (userContext.features.enableReactPane) {
|
||||
this.openAddCollectionPanel();
|
||||
|
||||
Reference in New Issue
Block a user