Changed chain signature + refactoring