Module:RFX tally

local p = {} local rfx = require("Module:RFX") function p.main(frame) local title = mw.text.trim(frame.args[1]) local obj if title == nil or #title == 0 then obj = rfx.new(mw.title.getCurrentTitle.fullText) else obj = rfx.new("Requests for global rights#" .. title) if obj == nil then obj = rfx.new("Requests for Stewardship#" .. title) end if obj == nil then obj = rfx.new("Requests for Comment#" .. title) end end if obj == nil then return "(?/?/?)" else return string.format("(%s/%s/%s)",obj.supports or "?",obj.abstains or "?",obj.opposes or "?") end end return p