Small refactoring
Merge pull request #16 from oleksiyk/performance

Small refactoring