Further update, refactoring