Refactored registration_pages.rb