refactoring local data