Actually, looking at the code again, your solution is
WRONG. The problem comes from the two different generations of Joomla core code (3.0 to 3.3 and 3.4 to 3.6).
In the first generation where JApplicationSite extends JApplication the method's signature is
public function redirect($url, $msg = '', $msgType = 'message', $moved = false)
In the second generation where JApplicationSite extends JApplicationCms the method's signature is
public function redirect($url, $status = 303)
However, as you can read in libraries/cms/application/cms.php lines 974 to 1014 you can
still use the four arguments call. In this case Joomla! will translate your arguments to the new style and then call parent::redirect(). In its turn, parent::redirect() is actually a call to JApplicationWeb::redirect(). However, as we can see in JApplicationCms line 1012 Joomla has a bug and does NOT translate the $moved boolean to an HTTP code integer. So, basically, you are reporting a Joomla! bug.
So despite us using the Joomla API per its documentation (docblocks), a bug in Joomla itself prevents the code from working properly. Since we have to support older versions of Joomla which do not support the new, two argument call to redirect() you'll have to live with it until we drop support for old Joomla versions – in the next version of Admin Tools, scheduled for late June to mid July.
Nicholas K. Dionysopoulos
Lead Developer and Director
🇬🇷Greek: native 🇬🇧English: excellent 🇫🇷French: basic • 🕐 My time zone is Europe / Athens
Please keep in mind my timezone and cultural differences when reading my replies. Thank you!