updated for userid issue