Sha256: f2f275fe3f8dec7518ab4b3f5b129e2fc5010c41273ecd2e7df593895072ef41
Contents?: true
Size: 332 Bytes
Versions: 15
Compression:
Stored size: 332 Bytes
Contents
# frozen_string_literal: true class APIConstraints def initialize(version:, default: false) @version = version @default = default end def matches?(req) @default || req.headers['Accept'].include?(version_string) end private def version_string "application/vnd.aaf.example.v#{@version}+json" end end
Version data entries
15 entries across 15 versions & 1 rubygems