gddo-server: fix redirect loop with canonical imports

Only redirect to canonical github project when the requested is a case
insensitive match, but not an exact match to the requested project.
Otherwise projects which have been moved to a new name, but use a
canonical import to the old name will result in a redirect loop.

Change-Id: I350359d802c3c42e47f2247ffee2469d6449eabc
Reviewed-on: https://go-review.googlesource.com/93176
Reviewed-by: Tuo Shan <shantuo@google.com>
1 file changed