Simplfy and debug