added type to errorcallback
Merge pull request #257 from nens/fritz_type_bug

added type to errorcallback