Refactor

Merging from refactor