Updated code to (attempt to) incorporate source_priority (#8).