Moved functions order