Added missing $GLOBALS['wp_rewrite']

Not setting $rules = $GLOBALS['wp_rewrite']->wp_rewrite_rules(); meant that the plugin flushed the rules every time the method ws called.

git-svn-id: http://plugins.svn.wordpress.org/my-permalink-demo/trunk@667584 b8457f37-d9ea-0310-8a92-e5e31aec5664
Merge branch 'master' of github.com:soderlind/my-permalink-demo