@@ -152,7 +152,7 @@ func (c *Client) Create(ctx context.Context, spec v1alpha1.ServiceInstanceParame
152152 return c .createManaged (ctx , spec , creds )
153153
154154 case v1alpha1 .UserProvidedService :
155- return c .createUserProvided (ctx , spec , creds )
155+ return c .createUserProvided (ctx , spec )
156156 default :
157157 return nil , errors .New ("unknown service instance type" )
158158 }
@@ -185,12 +185,7 @@ func (c *Client) createManaged(ctx context.Context, spec v1alpha1.ServiceInstanc
185185}
186186
187187// createUserProvided creates a user-provided service instance according to CR's ForProvider spec
188- func (c * Client ) createUserProvided (ctx context.Context , spec v1alpha1.ServiceInstanceParameters , creds json.RawMessage ) (* resource.ServiceInstance , error ) {
189- // Credential is required for UPS
190- if creds == nil {
191- return nil , errors .New ("Missing or invalid credentials" )
192- }
193-
188+ func (c * Client ) createUserProvided (ctx context.Context , spec v1alpha1.ServiceInstanceParameters ) (* resource.ServiceInstance , error ) {
194189 // throw error if no space is provided
195190 if spec .Space == nil {
196191 return nil , errors .New ("no space reference provided" )
@@ -204,7 +199,6 @@ func (c *Client) createUserProvided(ctx context.Context, spec v1alpha1.ServiceIn
204199
205200 // workaround: cf-goclient supports few ups options at creation time.
206201 upt := resource .NewServiceInstanceUserProvidedUpdate ().
207- WithCredentials (creds ).
208202 WithRouteServiceURL (spec .RouteServiceURL ).
209203 WithSyslogDrainURL (spec .SyslogDrainURL )
210204
0 commit comments