You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: model_errors.rb
    path of file: ./repos/dsu/lib/dsu/views/shared
    
    the code of the file until where you have to start completion: # frozen_string_literal: true

require_relative 'error'

module Dsu
  module Views
    module Shared
      class ModelErrors < Error
        def initialize(model:, options: {})
          raise ArgumentError, 'model is nil'
    
        def initialize(model:, options: {})
          raise ArgumentError, 'model is nil' if model.nil?
          raise ArgumentError, "model is the wrong object type: \"#{model}\"" unless model.is_a?(ActiveModel::Model)

          # TODO: I18n.
          header = options[:header] || 'The following ERRORS were encountered; changes could not be saved:'
          super(messages: model.errors.full_messages, header: header, options: options)

          @model = model
        end