Remove the close() as it might cause issues.