remove debug output
switch to OOP