Changed the delegates. Should fix GitHub issue #45