final changes, now it works!