Added previous exception in toArray().