FIxed serialization.
Addressed warning about problematic try.