fixed a bug with markdown export