diff --git a/bundle/direct/dresources/postgres_branch.go b/bundle/direct/dresources/postgres_branch.go index 4f234d947dc..82b50f8a10c 100644 --- a/bundle/direct/dresources/postgres_branch.go +++ b/bundle/direct/dresources/postgres_branch.go @@ -78,13 +78,9 @@ func makePostgresBranchRemote(branch *postgres.Branch) *PostgresBranchRemote { if branch.Spec != nil { spec = *branch.Spec } - var branchID string - if branch.Status != nil { - branchID = branch.Status.BranchId - } return &PostgresBranchRemote{ BranchSpec: spec, - BranchId: branchID, + BranchId: branch.BranchId, Parent: branch.Parent, Name: branch.Name, Status: branch.Status, diff --git a/bundle/direct/dresources/postgres_database.go b/bundle/direct/dresources/postgres_database.go index d412eb94b8c..8d98606d70d 100644 --- a/bundle/direct/dresources/postgres_database.go +++ b/bundle/direct/dresources/postgres_database.go @@ -72,13 +72,9 @@ func makePostgresDatabaseRemote(database *postgres.Database) *PostgresDatabaseRe if database.Spec != nil { spec = *database.Spec } - var databaseID string - if database.Status != nil { - databaseID = database.Status.DatabaseId - } return &PostgresDatabaseRemote{ DatabaseDatabaseSpec: spec, - DatabaseId: databaseID, + DatabaseId: database.DatabaseId, Parent: database.Parent, Name: database.Name, Status: database.Status, diff --git a/bundle/direct/dresources/postgres_endpoint.go b/bundle/direct/dresources/postgres_endpoint.go index eef2cd766e1..c370ff120be 100644 --- a/bundle/direct/dresources/postgres_endpoint.go +++ b/bundle/direct/dresources/postgres_endpoint.go @@ -87,13 +87,9 @@ func makePostgresEndpointRemote(endpoint *postgres.Endpoint) *PostgresEndpointRe if endpoint.Spec != nil { spec = *endpoint.Spec } - var endpointID string - if endpoint.Status != nil { - endpointID = endpoint.Status.EndpointId - } return &PostgresEndpointRemote{ EndpointSpec: spec, - EndpointId: endpointID, + EndpointId: endpoint.EndpointId, Parent: endpoint.Parent, Name: endpoint.Name, Status: endpoint.Status, diff --git a/bundle/direct/dresources/postgres_project.go b/bundle/direct/dresources/postgres_project.go index d6bd118dd64..02830b5d606 100644 --- a/bundle/direct/dresources/postgres_project.go +++ b/bundle/direct/dresources/postgres_project.go @@ -80,13 +80,9 @@ func makePostgresProjectRemote(project *postgres.Project) *PostgresProjectRemote if project.Spec != nil { spec = *project.Spec } - var projectID string - if project.Status != nil { - projectID = project.Status.ProjectId - } return &PostgresProjectRemote{ ProjectSpec: spec, - ProjectId: projectID, + ProjectId: project.ProjectId, InitialEndpointSpec: project.InitialEndpointSpec, Name: project.Name, Status: project.Status, diff --git a/bundle/direct/dresources/postgres_role.go b/bundle/direct/dresources/postgres_role.go index 2e0932e0c9b..d9e70b2feb5 100644 --- a/bundle/direct/dresources/postgres_role.go +++ b/bundle/direct/dresources/postgres_role.go @@ -85,13 +85,9 @@ func makePostgresRoleRemote(role *postgres.Role) *PostgresRoleRemote { if role.Spec != nil { spec = *role.Spec } - var roleID string - if role.Status != nil { - roleID = role.Status.RoleId - } return &PostgresRoleRemote{ RoleRoleSpec: spec, - RoleId: roleID, + RoleId: role.RoleId, Parent: role.Parent, Name: role.Name, Status: role.Status,