module WithMetadata
  extend ActiveSupport::Concern

  included do
    serialize :metadata, Mumukit::Auth::Metadata

    validates_presence_of :metadata

    delegate :student?, :admin?, to: :metadata

    def teacher?(slug) ## BIG FIX ME
      metadata.permissions('classroom').present?
    end
  end

end

module WithMetadata
  extend ActiveSupport::Concern

  included do
    serialize :metadata, Mumukit::Auth::Metadata

    validates_presence_of :metadata

    delegate :student?, :teacher?, :admin?, to: :metadata
  end

end
Revert "Quick teacher exam fix"
Revert "Quick teacher exam fix"

This reverts commit 88a0dd8842fc4046a3b572432468737773d97b90.
