Изменения

Строка 53: Строка 53:  
}
 
}
 
 
if is_empty(args[1]) and ( is_empty(args['есть']) or not args['есть']:match('^:[a-z-]+:') ) then
+
if is_empty(args[1]) then
 
if allow_cat then
 
if allow_cat then
 
categories = categories .. orphan_categories['error']
 
categories = categories .. orphan_categories['error']
Строка 60: Строка 60:  
end
 
end
   −
if not is_empty(args['есть']) or args[1]:match('^:[a-z-]+:') then
+
if args[1]:match('^:[a-z-]+:') then
local temp
+
local temp = args[1]
if is_empty(args['есть']) then
+
args[1] = args[2] or ''
temp = args[1]
+
args[2] = args[3]
else
  −
temp = args['есть']
  −
end
  −
args[1] = args['надо'] or args['нужно'] or args[2] or ''
  −
args[2] = args['текст'] or args[3]
   
args[3] = temp:gsub('^:([a-z-]+):(.+)$', '%1')
 
args[3] = temp:gsub('^:([a-z-]+):(.+)$', '%1')
 
args[4] = temp:gsub('^:([a-z-]+):(.+)$', '%2')
 
args[4] = temp:gsub('^:([a-z-]+):(.+)$', '%2')
Анонимный участник