Fixes major bug where url is not formed when no pk is given