fixes from codestreamer at https://bugs.flyspray.org/task/1911 part 2