Fixes bug 1071347 - Fixed assert function