Moved logic to onCreate rather than onStart