bugfix
[NOT COMPILABLE] Refactoring