         />
 
     render_payment_methods: ->
+        # this happens, when it is a customer but all credit cards are deleted!
+        return null if not @props.sources?
         for source in @props.sources.data
             @render_payment_method(source)
 

    render_add_subscription_button: ->
        <Button
            bsStyle   = 'primary'
            disabled  = {@state.state isnt 'view' or @props.sources.total_count is 0}
            onClick   = {=>@setState(state : 'add_new')}
            className = 'pull-right' >
            <Icon name='plus-circle' /> Add Subscription or Course Package...


    propTypes :
        subscriptions   : rtypes.object
        sources         : rtypes.object # could be undefined, if it is a customer but all cards are removed
        selected_plan   : rtypes.string
        redux           : rtypes.object.isRequired
        applied_coupons : rtypes.immutable.Map
