@@ -130,26 +130,6 @@ func (oa *OpenAPI) GenerateDefaultProjectApiKey(ctx *gin.Context) {
130130 }
131131}
132132
133- func (oa * OpenAPI ) BecomeAnotherCloudUser (ctx * gin.Context , params openapi.BecomeAnotherCloudUserParams ) {
134- if ctx .IsAborted () {
135- return
136- }
137-
138- if authorizator , err := oa .Authorizator .Cloud (); err != nil {
139- mw .Unsupported (ctx , err )
140- } else if authority , err := mw .GetAuthority (ctx ); err != nil {
141- mw .Unauthorized (ctx , err )
142- } else if ! authority .IsAdmin {
143- mw .Forbidden (ctx , "Only admins can use this API method" )
144- } else if params .UserId == "" {
145- mw .RequiredField (ctx , "user_id" )
146- } else if token , err := authorizator .SignInAs (ctx , params .UserId ); err != nil {
147- mw .BadRequest (ctx , "sign in failed" , err )
148- } else {
149- ctx .JSON (http .StatusOK , token )
150- }
151- }
152-
153133func (oa * OpenAPI ) CreateFreeTierPostgresDatabase (ctx * gin.Context ) {
154134 if ctx .IsAborted () {
155135 return
@@ -445,7 +425,6 @@ func (oa *OpenAPI) GetSystemConfiguration(ctx *gin.Context) {
445425 DefaultS3Bucket : ! oa .SystemConfig .SelfHosted ,
446426 SupportTrackingDomains : ! oa .SystemConfig .SelfHosted ,
447427 TelemetryUsageDisabled : telemetryUsageDisabled ,
448- ShowBecomeUser : ! oa .SystemConfig .SelfHosted ,
449428 DockerHubID : oa .SystemConfig .DockerHUBID ,
450429 OnlyAdminCanChangeUserEmail : oa .SystemConfig .SelfHosted ,
451430 Tag : oa .SystemConfig .Tag ,
0 commit comments