Skip to content

TypeError: Cannot read property 'service' of undefined #17

@Snapu

Description

@Snapu

On the spaceDetails page, services can't be loaded due to the following error:

libs.min.js:100 TypeError: Cannot read property 'service' of undefined
    at application.min.js:3
    at Object.s [as forEach] (libs.min.js:7)
    at application.min.js:3
    at libs.min.js:109
    at h.$eval (libs.min.js:123)
    at h.$digest (libs.min.js:120)
    at h.$apply (libs.min.js:123)
    at n (libs.min.js:80)
    at O (libs.min.js:84)
    at XMLHttpRequest.D.onload (libs.min.js:85)

It is this part of the code:

        angular.forEach(response.data.services, function(service, i) {
          var objectService = {
            id: service.guid,
            name: service.name,
            servicePlan: service.service_plan.service.label + ', ' + service.service_plan.name,
            nrOfBoundApps: service.bound_app_count,
            dashboardUrl: service.dashboard_url,
            supportURL:'https://support.'+service.service_plan.service.label+'.com/',
            docsURL: 'http://docs.run.pivotal.io/marketplace/services/'+service.service_plan.service.label+'.html'
          };

Don't know if it is a general bug. Anyway, I am trying to fix it now.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions