fixed warnings bug