def add_script(identifier, **opts)
      id = validate_script_opts(identifier, opts)

      return nil if @scripts.map { |s| s[:id] }.include? id

      name = JSS::Script.map_all_ids_to(:name, api: @api)[id]

      script_data = {
        id: id,
        name: name,
        priority: SCRIPT_PRIORITIES[opts[:priority]],
        parameter4: opts[:parameter4],
        parameter5: opts[:parameter5],
        parameter6: opts[:parameter6],
        parameter7: opts[:parameter7],
        parameter8: opts[:parameter8],
        parameter9: opts[:parameter9],
        parameter10: opts[:parameter10],
        parameter11: opts[:parameter11]
      }

      @scripts.insert opts[:position], script_data

      @need_to_update = true
      @scripts
    end
def add_script(identifier, **opts)
      id = validate_script_opts(identifier, opts)

      return nil if @scripts.map { |s| s[:id] }.include? id

      name = JSS::Script.map_all_ids_to(:name, api: @api)[id]

      script_data = {
        id: id,
        name: name,
        priority: SCRIPT_PRIORITIES[opts[:priority]],
        parameter4: opts[:parameter4],
        parameter5: opts[:parameter5],
        parameter6: opts[:parameter6],
        parameter7: opts[:parameter7],
        parameter8: opts[:parameter8],
        parameter9: opts[:parameter9],
        parameter10: opts[:parameter10],
        parameter11: opts[:parameter11]
      }

      @scripts.insert opts[:position], script_data

      @need_to_update = true
      @scripts
    end
Add a script to the list of SCRIPT_PRIORITIESipts run by this policy.
 If the script already exists in the policy, nil is returned and
 no changes are made.

 @param [String,Integer] identifier the name or id of the script to add to this policy

 @param [Hash] opts the options for this script

 @option [Symbol, Integer] position: where to add this script among the list of
   scripts. Zero-based, :start and 0 are the same, as are :end and -1. Defaults to :end

 @option [Symbol] priority: either :before or :after

 @option [String] parameter4: the value of the 4th parameter passed to the script. this
   overrides the same parameter in the script object itself.

 @option [String] parameter5: the value of the 5th parameter passed to the script. this
   overrides the same parameter in the script object itself.

 @option [String] parameter6: the value of the 6th parameter passed to the script. this
   overrides the same parameter in the script object itself.

 @option [String] parameter7: the value of the 7th parameter passed to the script. this
   overrides the same parameter in the script object itself.

 @option [String] parameter8: the value of the 8th parameter passed to the script. this
   overrides the same parameter in the script object itself.

 @option [String] parameter9: the value of the 9th parameter passed to the script. this
   overrides the same parameter in the script object itself.

 @option [String] parameter10: the value of the 10th parameter passed to the script. this
   overrides the same parameter in the script object itself.

 @option [String] parameter11: the value of the 11th parameter passed to the script. this
   overrides the same parameter in the script object itself.

 @return [Array, nil]  the new @scripts array, nil if script was already in the policy