Removed some warnings, unused variable