diff --git a/LICENSE b/LICENSE
--- a/LICENSE
+++ b/LICENSE
@@ -1,4 +1,4 @@
-Copyright (c) 2014, Andrey Basko
+Copyright (c) 2014-2015, Andrey Basko
 
 All rights reserved.
 
diff --git a/linkedhashmap.cabal b/linkedhashmap.cabal
--- a/linkedhashmap.cabal
+++ b/linkedhashmap.cabal
@@ -2,7 +2,7 @@
 -- documentation, see http://haskell.org/cabal/users-guide/
 
 name:                linkedhashmap
-version:             0.3.0.0
+version:             0.4.0.0
 license:             BSD3
 license-file:        LICENSE
 author:              Andrey Basko
@@ -43,10 +43,10 @@
                        Data.LinkedHashMap.IntMap
   -- other-modules:       
   other-extensions:    BangPatterns
-  build-depends:       base >=4.7 && <4.8
+  build-depends:       base >=4.6 && <5
                      , containers >=0.5 && <0.6
-                     , deepseq >= 1.1
-                     , hashable >=1.2 && <1.3
+                     , deepseq >=1.1 && <2
+                     , hashable >=1.2 && <2
                      , unordered-containers >=0.2 && <0.3
   hs-source-dirs:      src
   default-language:    Haskell2010
@@ -54,14 +54,10 @@
 test-suite linkedhashmap-tests
   type: exitcode-stdio-1.0
   main-is: Main.hs
-  build-depends:       base >=4.7 && <4.8
-                     , containers >= 0.5.5.1
-                     , deepseq >= 1.1
-                     , hashable >= 1.2.2.0
-                     , tasty >= 0.10.0.2
-                     , mtl >= 2.1.3.1
-                     , tasty-hunit >= 0.9.0.1
-                     , unordered-containers >= 0.2.5.0
+  build-depends:       base, containers, deepseq, hashable, unordered-containers
+                     , mtl >=2.1 && <3
+                     , tasty >=0.10 && <0.11
+                     , tasty-hunit >=0.9 && <0.10
   hs-source-dirs:      tests
                        src
   default-language:    Haskell2010
@@ -71,14 +67,8 @@
   main-is:        Main.hs
   hs-source-dirs:      benchmarks
                        src 
-  build-depends:       base >=4.7 && <4.8
-                     , containers >= 0.5.5.1
-                     , hashable >= 1.2.2.0
-                     , tasty >= 0.10.0.2
-                     , tasty-hunit >= 0.9.0.1
-                     , unordered-containers >= 0.2.5.0
-                     , criterion >= 1.0.2.0
-                     , deepseq >=1.3 && <1.4
+  build-depends:       base, containers, deepseq, hashable, unordered-containers
+                     , criterion >=1 && <2
   default-language:    Haskell2010
   ghc-options:      -O2
                     -fmax-simplifier-iterations=10
diff --git a/src/Data/LinkedHashMap/Seq.hs b/src/Data/LinkedHashMap/Seq.hs
--- a/src/Data/LinkedHashMap/Seq.hs
+++ b/src/Data/LinkedHashMap/Seq.hs
@@ -127,7 +127,7 @@
   where 
     m' = M.insert k (Entry ix' v) m
     (s', ix', n') = case M.lookup k m of
-                      Just (Entry ix _) -> (s, ix, n)
+                      Just (Entry ix _) -> (S.update ix (JustPair k v) s, ix, n)
                       Nothing -> (s |> JustPair k v, S.length s, n+1)
 {-# INLINABLE insert #-}
 
diff --git a/tests/Main.hs b/tests/Main.hs
--- a/tests/Main.hs
+++ b/tests/Main.hs
@@ -99,6 +99,9 @@
 test23_1 = LM1.fromListWith (\v1 v2 -> v2 ++ v1) [(1 :: Int,"A"), (5, "B"), (7, "C"), (-6, "D"), (1 :: Int,"ZZZ")]
 test23_2 = LM2.fromListWith (\v1 v2 -> v2 ++ v1) [(1 :: Int,"A"), (5, "B"), (7, "C"), (-6, "D"), (1 :: Int,"ZZZ")]
 
+test24_1 = LM1.insert 5 "D" test0_1
+test24_2 = LM2.insert 5 "D" test0_2
+
 unitTests :: TestTree
 unitTests = testGroup "Unit tests"
   [ testCase "test0" $ LM1.toList test0_1 @?= LM2.toList test0_2,
@@ -131,7 +134,9 @@
     testCase "test20" $ test20_1 @?= test20_2,
     testCase "test21" $ LM1.toList test21_1 @?= LM2.toList test21_2,
     testCase "test22" $ LM1.toList test22_1 @?= LM2.toList test22_2,
-    testCase "test23" $ LM1.toList test23_1 @?= LM2.toList test23_2
+    testCase "test23" $ LM1.toList test23_1 @?= LM2.toList test23_2,
+    testCase "test24_1" $ LM1.toList test24_1 @?= LM2.toList test24_2,
+    testCase "test24_2" $ LM1.toList test24_1 @?= [(1,"A"),(5,"D"),(7,"C"),(-6,"C")]
   ]
 
 main :: IO ()
