Improved the hidden field so that it checks correctly