Fixes code snippet in preferences.md

It was not closing the block properly and a lot of text was stuck inside a code block.