Open arfon opened 7 years ago
Well if it works then I must be wrong and I would just leave it in so the icons are consistent.
perhaps we should just show this if they have an assigned paper that they haven't commented on?
That is the best short-term solution. Otherwise I have to create a flag and code to track if they have viewed a paper. Do people generally leave at least one comment on a paper? Maybe we should change the text slightly to 'You have not commented on a paper you have been assigned to' or similar. I suggest we just create a method and we can change the implementation later when we can. Just leave a todo and/or create a github issue.
As part of this change I think that we should change the redirect_url
SessionController#create
to something like:
redirect_url = request.env['omniauth.origin'] || default_url_for(user)
...
protected
def default_url_for(user)
if ( [user is an editor or reviewer] )
dashboard_path
else
recent_path
end