bugfix in the serialization
checked all todos and the exception handling