Files
fizzy/app/controllers/qr_codes_controller.rb
T
David Heinemeier Hansson 1b732c41c7 Use render svg
2025-04-12 18:15:05 +02:00

9 lines
265 B
Ruby

class QrCodesController < ApplicationController
allow_unauthenticated_access
def show
expires_in 1.year, public: true
render svg: RQRCode::QRCode.new(QrCodeLink.from_signed(params[:id]).url).as_svg(viewbox: true, fill: :white, color: :black)
end
end