Wed refactor