Added temp. debug function