improve registration controller