lib: refactoring
Merge pull request #6 from LinusU/patch-4

lib: refactoring