modify default location
Merge Weijj's code