Изменения
Модуль:Надстрочное предупреждение (посмотреть исходный код)
Версия от 03:42, 16 мая 2023
, 2 года назадfix
local success, result = pcall(mwLang.formatDate, mwLang, 'U', dateString)
local success, result = pcall(mwLang.formatDate, mwLang, 'U', dateString)
if success then
if success then
if tonumber( result ) then
return result
return result
end
end
local mDate = require( 'Module:Date' )._Date
local mDate = require( 'Module:Date' )._Date
local today = mwLang:formatDate( 'Y-m-d H:i:s' )
local today = mwLang:formatDate( 'Y-m-d H:i:s' )
local input = mwLang:formatDate( 'Y-m-d H:i:s', tostring( date ) )
local input = mwLang:formatDate( 'Y-m-d H:i:s', date )
local diff = ( mDate( today ) - mDate( input ) )
local diff = ( mDate( today ) - mDate( input ) )