Jump to content

Module talk:Category handler

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia
This is an old revision of this page, as edited by Jayarathina (talk | contribs) at 15:48, 17 November 2013 (Error in Implementing this Module). The present address (URL) is a permanent link to this revision, which may differ significantly from the current revision.

Error in Implementing this Module

I copied this module to my local wiki (Tamil). When I use this in {{mbox}} as {{#invoke:Message box|mbox}} , I get the following error:

Lua error in Module:Category_handler at line 231: attempt to call field '_main' (a nil value).

Backtrace:
   Module:Category_handler:231: ?
   (tail call): ?
   Module:Message_box:409: in function "setBoxParameters"
   Module:Message_box:539: ?
   (tail call): ?
   mw.lua:553: ?

I can see that the error is in this module at line number 231: Which is:

local data = nsDetect._main(ndargs)

Can someone please help me? --Jayarathina (talk) 15:15, 17 November 2013 (UTC)[reply]

I'm no Lua expert; you may want to ask the user who actually wrote this module, Mr. Stradivarius. At a glance the problem seems to be that this module tries to call a field that doesn't contain a value. This field seems to come from Module:Namespace detect. Did you copy that module to the Tamil Wikipedia, too? If not, that's likely the reason for the error. Huon (talk) 15:37, 17 November 2013 (UTC)[reply]
Huon, Thanks a lot. It was already copied, but it was of an old revision of the Module:Namespace detect. I updated it and the error vanished. Thanks a lot. --Jayarathina (talk) 15:48, 17 November 2013 (UTC)[reply]