fixing bug with first time load of dashboard page