Moved registry to a class