Cleanup

More elegant code