Push installation `parse_results': undefined method `map' for nil:NilClass

I run ionic cordova plugin add phonegap-plugin-push --variable SENDER_ID=XXXXXXXXX

i get the error:

push installation parse_results': undefined methodmap’ for nil:NilClass

global packages:

    @ionic/cli-utils : 1.5.0
    Cordova CLI      : 7.0.0 
    Ionic CLI        : 3.5.0

local packages:

    @ionic/app-scripts              : 1.3.0
    @ionic/cli-plugin-cordova       : 1.4.1
    @ionic/cli-plugin-ionic-angular : 1.3.2
    Cordova Platforms               : android 6.2.3 browser 4.1.0 ios 4.4.0
    Ionic Framework                 : ionic-angular 3.0.1

System:

    Node       : v8.0.0
    OS         : macOS Sierra
    Xcode      : Xcode 8.3.3 Build version 8E3004b 
    ios-deploy : 1.9.1 
    ios-sim    : 6.0.0 
    npm        : 5.0.0 

What is the problem? My system is fairly up to date.

Turns out I needed to install cocoapods