fixed undefined index with registration form