Corrected url paths for the dynamic flow links and improved logic