Tidy up topic handling.

Change-Id: If0a0609ab778df22c02b8dc1d349da45b4b5b16f
Depends-On: I9e8723fe0fe2b9209a401d33361f80fb832b9434
Reviewed-on: http://gerrit.dmdirc.com/3414
Automatic-Compile: DMDirc Build Manager
Reviewed-by: Greg Holmes <greg@dmdirc.com>