added preferred location functionality
tested. works.