Second task corrected Dispose method