diff --git a/ChangeLog.md b/ChangeLog.md
--- a/ChangeLog.md
+++ b/ChangeLog.md
@@ -1,5 +1,9 @@
 # Revision history for irc-core
 
+## 2.4.0
+
+* Change TOPIC and INVITING replies to channel target
+
 ## 2.3.0 -- 2017-06-02
 
 * Change type of `idDenote` to save a bit of memory
diff --git a/irc-core.cabal b/irc-core.cabal
--- a/irc-core.cabal
+++ b/irc-core.cabal
@@ -1,10 +1,9 @@
 name:                irc-core
-version:             2.3.0
+version:             2.4.0
 synopsis:            IRC core library for glirc
 description:         IRC core library for glirc
                      .
                      The glirc client has been split off into <https://hackage.haskell.org/package/glirc>
-homepage:            https://github.com/glguy/irc-core
 license:             ISC
 license-file:        LICENSE
 author:              Eric Mertens
@@ -33,14 +32,14 @@
                        Irc.UserInfo
   other-modules:       View
 
-  build-depends:       base       >=4.9  && <4.11,
+  build-depends:       base       >=4.9  && <4.12,
                        base64-bytestring >= 1.0.0.1 && <1.1,
                        attoparsec >=0.13 && <0.14,
                        bytestring >=0.10 && <0.11,
                        hashable   >=1.2  && <1.3,
                        primitive  >=0.6  && <0.7,
                        text       >=1.2  && <1.3,
-                       time       >=1.6  && <1.9,
+                       time       >=1.6  && <1.10,
                        vector     >=0.11 && <0.13
 
   hs-source-dirs:      src
diff --git a/src/Irc/Codes.hs b/src/Irc/Codes.hs
--- a/src/Irc/Codes.hs
+++ b/src/Irc/Codes.hs
@@ -206,7 +206,7 @@
 pattern RPL_MOTDSTART               = ReplyCode 375
 pattern RPL_ENDOFMOTD               = ReplyCode 376
 pattern RPL_WHOISHOST               = ReplyCode 378
-pattern RPL_KICKLINKED              = ReplyCode 379
+pattern RPL_WHOISMODES              = ReplyCode 379
 pattern RPL_YOUREOPER               = ReplyCode 381
 pattern RPL_REHASHING               = ReplyCode 382
 pattern RPL_YOURESERVICE            = ReplyCode 383
@@ -633,7 +633,7 @@
   , (RPL_MOTDSTART             , ReplyCodeInfo CommandReply "motd-start")
   , (RPL_ENDOFMOTD             , ReplyCodeInfo CommandReply "end-of-motd")
   , (RPL_WHOISHOST             , ReplyCodeInfo CommandReply "whois-host")
-  , (RPL_KICKLINKED            , ReplyCodeInfo CommandReply "kick-linked")
+  , (RPL_WHOISMODES            , ReplyCodeInfo CommandReply "whois-modes")
   , (RPL_YOUREOPER             , ReplyCodeInfo CommandReply "youre-oper")
   , (RPL_REHASHING             , ReplyCodeInfo CommandReply "rehashing")
   , (RPL_YOURESERVICE          , ReplyCodeInfo CommandReply "youre-service")
diff --git a/src/Irc/Message.hs b/src/Irc/Message.hs
--- a/src/Irc/Message.hs
+++ b/src/Irc/Message.hs
@@ -182,31 +182,38 @@
 msgTarget :: Identifier -> IrcMsg -> MessageTarget
 msgTarget me msg =
   case msg of
-    UnknownMsg{}                  -> TargetNetwork
-    Nick user _                   -> TargetUser (userNick user)
-    Mode _ tgt _ | tgt == me      -> TargetNetwork
-                 | otherwise      -> TargetWindow tgt
-    Join _ chan                   -> TargetWindow chan
-    Part _ chan _                 -> TargetWindow chan
-    Quit user _                   -> TargetUser (userNick user)
-    Kick _ chan _ _               -> TargetWindow chan
-    Topic _ chan _                -> TargetWindow chan
-    Privmsg src tgt _ | tgt == me -> TargetWindow (userNick src)
-                      | otherwise -> TargetWindow tgt
-    Ctcp src tgt _ _  | tgt == me -> TargetWindow (userNick src)
-                      | otherwise -> TargetWindow tgt
-    CtcpNotice src tgt _ _  | tgt == me -> TargetWindow (userNick src)
-                            | otherwise -> TargetWindow tgt
-    Notice  src tgt _ | tgt == me -> TargetWindow (userNick src)
-                      | otherwise -> TargetWindow tgt
-    Authenticate{}                -> TargetHidden
-    Ping{}                        -> TargetHidden
-    Pong{}                        -> TargetHidden
-    Error{}                       -> TargetNetwork
-    Cap{}                         -> TargetNetwork
-    Reply{}                       -> TargetNetwork
-    BatchStart{}                  -> TargetHidden
-    BatchEnd{}                    -> TargetHidden
+    UnknownMsg{}             -> TargetNetwork
+    Nick user _              -> TargetUser (userNick user)
+    Mode _ tgt _ | tgt == me -> TargetNetwork
+                 | otherwise -> TargetWindow tgt
+    Join _ chan              -> TargetWindow chan
+    Part _ chan _            -> TargetWindow chan
+    Quit user _              -> TargetUser (userNick user)
+    Kick _ chan _ _          -> TargetWindow chan
+    Topic _ chan _           -> TargetWindow chan
+    Privmsg src tgt _        -> directed src tgt
+    Ctcp src tgt _ _         -> directed src tgt
+    CtcpNotice src tgt _ _   -> directed src tgt
+    Notice  src tgt _        -> directed src tgt
+    Authenticate{}           -> TargetHidden
+    Ping{}                   -> TargetHidden
+    Pong{}                   -> TargetHidden
+    Error{}                  -> TargetNetwork
+    Cap{}                    -> TargetNetwork
+    Reply code args          -> replyTarget code args
+    BatchStart{}             -> TargetHidden
+    BatchEnd{}               -> TargetHidden
+  where
+    directed src tgt
+      | Text.null (userHost src) = TargetNetwork -- server message
+      | tgt == me = TargetWindow (userNick src)
+      | otherwise = TargetWindow tgt
+      where
+        src' = userNick src
+
+    replyTarget RPL_TOPIC    (_:chan:_)   = TargetWindow (mkId chan)
+    replyTarget RPL_INVITING (_:_:chan:_) = TargetWindow (mkId chan)
+    replyTarget _                _        = TargetNetwork
 
 -- | 'UserInfo' of the user responsible for a message.
 msgActor :: IrcMsg -> Maybe UserInfo
diff --git a/src/Irc/RawIrcMsg.hs b/src/Irc/RawIrcMsg.hs
--- a/src/Irc/RawIrcMsg.hs
+++ b/src/Irc/RawIrcMsg.hs
@@ -255,9 +255,9 @@
   <> Text.encodeUtf8Builder (renderUserInfo u)
   <> Builder.char8 ' '
 
--- | Build concatenate a list of parameters into a single, space-
--- delimited bytestring. Use a colon for the last parameter if it contains
--- a colon or a space.
+-- | Concatenate a list of parameters into a single, space-delimited
+-- bytestring. Use a colon for the last parameter if it starts with
+-- a colon or contains a space.
 buildParams :: [Text] -> Builder
 buildParams [x]
   | " " `Text.isInfixOf` x || ":" `Text.isPrefixOf` x
