CADMIUM-161: Fixed problem found in redirect code that was causing a

null pointer exception