Switch back to SDK for deleteDatabase and use RP for readCollections for table API (#155)
This commit is contained in:
parent
3279460cfd
commit
951289e190
|
@ -15,7 +15,7 @@ export async function deleteDatabase(databaseId: string): Promise<void> {
|
||||||
const clearMessage = logConsoleProgress(`Deleting database ${databaseId}`);
|
const clearMessage = logConsoleProgress(`Deleting database ${databaseId}`);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
if (window.authType === AuthType.AAD) {
|
if (window.authType === AuthType.AAD && userContext.defaultExperience !== DefaultAccountExperienceType.Table) {
|
||||||
await deleteDatabaseWithARM(databaseId);
|
await deleteDatabaseWithARM(databaseId);
|
||||||
} else {
|
} else {
|
||||||
await client()
|
await client()
|
||||||
|
|
|
@ -16,11 +16,7 @@ export async function readCollections(databaseId: string): Promise<DataModels.Co
|
||||||
let collections: DataModels.Collection[];
|
let collections: DataModels.Collection[];
|
||||||
const clearMessage = logConsoleProgress(`Querying containers for database ${databaseId}`);
|
const clearMessage = logConsoleProgress(`Querying containers for database ${databaseId}`);
|
||||||
try {
|
try {
|
||||||
if (
|
if (window.authType === AuthType.AAD && userContext.defaultExperience !== DefaultAccountExperienceType.MongoDB) {
|
||||||
window.authType === AuthType.AAD &&
|
|
||||||
userContext.defaultExperience !== DefaultAccountExperienceType.MongoDB &&
|
|
||||||
userContext.defaultExperience !== DefaultAccountExperienceType.Table
|
|
||||||
) {
|
|
||||||
collections = await readCollectionsWithARM(databaseId);
|
collections = await readCollectionsWithARM(databaseId);
|
||||||
} else {
|
} else {
|
||||||
const sdkResponse = await client()
|
const sdkResponse = await client()
|
||||||
|
|
Loading…
Reference in New Issue