Badly injured dog rescued just on time!