You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
$databaseId = $this->determineDatabaseServer('On which database server would you like to create the new database user?', $input, $output);
47
46
$databases = [];
47
+
$databaseServer = $this->apiClient->getDatabaseServer($this->determineDatabaseServer('On which database server would you like to create the new database user?', $input, $output));
if (empty($username) && $input->isInteractive()) {
51
51
$username = $output->ask('What is the username of the new database user');
52
52
}
53
53
54
-
if (!$output->confirm('Do you want to the new user to have access to all databases?', false)) {
55
-
$databases = $output->multichoice('Please enter the comma-separated list of databases that you want the user to have access to', $this->apiClient->getDatabases($databaseId)->all());
54
+
if ($databaseServer['publicly_accessible'] && !$output->confirm('Do you want to the new user to have access to all databases?', false)) {
55
+
$databases = $output->multichoice('Please enter the comma-separated list of databases that you want the user to have access to', $this->apiClient->getDatabases($databaseServer['id'])->all());
$databaseId = $this->determineDatabaseServer('On which database server would you like to delete a database user?', $input, $output);
47
+
$databaseServer = $this->apiClient->getDatabaseServer($this->determineDatabaseServer('On which database server would you like to create the new database user?', $input, $output));
0 commit comments