fix bug in set target without url scheme