Module:Protection banner: Difference between revisions

Jump to navigation Jump to search
allow specifying a data table to config objects for testing purposes
(use lang:formatDate instead of os.date as it is easier to localise)
(allow specifying a data table to config objects for testing purposes)
Line 18:
local Config = class('Config')
 
function Config:initialize(data)
local data = data or mw.loadData('Module:Protection banner/config')
self._cfg = data.cfg
self._msg = data.msg
Cookies help us deliver our services. By using our services, you agree to our use of cookies.

Navigation menu