Revert "Merge branch 'refactor' into dev"

This reverts commit 2f3a53ab06ad02554ccd219eaed96bb1cbd73d4a, reversing
changes made to ea49e99f8d6c862bbdd849590573c91e9e4bb893.