unified swirl
code cleanup
refactorings