Permalinks incorrectly inserting multiple categories

Looks like it was trying to create a taxonomy called category which was causing odd behaviour, ripping this code out did the trick, though some rewrite rules were necessary to make paginated archive pages work.