Update lib.php

Adding possibility to rewrite category info