Removed if() and used selected() instead.