diff --git a/Gemfile.lock b/Gemfile.lock
index ac1fb8692f0e3e4234b380825dba84e9fcd8ab28..420d918d6e965770ae84801dc467ded4fa8db4f3 100644
--- a/Gemfile.lock
+++ b/Gemfile.lock
@@ -210,7 +210,7 @@ GEM
       activerecord
       kaminari-core (= 1.0.1)
     kaminari-core (1.0.1)
-    kramdown (1.14.0)
+    kramdown (1.15.0)
     libv8 (3.16.14.19)
     listen (3.1.5)
       rb-fsevent (~> 0.9, >= 0.9.4)
@@ -301,7 +301,7 @@ GEM
       thor (>= 0.18.1, < 2.0)
     rainbow (2.2.2)
       rake
-    rake (12.0.0)
+    rake (12.1.0)
     ransack (1.8.3)
       actionpack (>= 3.0)
       activerecord (>= 3.0)
@@ -317,14 +317,14 @@ GEM
     responders (2.4.0)
       actionpack (>= 4.2.0, < 5.3)
       railties (>= 4.2.0, < 5.3)
-    rubocop (0.49.1)
+    rubocop (0.50.0)
       parallel (~> 1.10)
       parser (>= 2.3.3.1, < 3.0)
       powerpack (~> 0.1)
-      rainbow (>= 1.99.1, < 3.0)
+      rainbow (>= 2.2.2, < 3.0)
       ruby-progressbar (~> 1.7)
       unicode-display_width (~> 1.0, >= 1.0.1)
-    ruby-progressbar (1.8.1)
+    ruby-progressbar (1.8.3)
     ruby_dep (1.5.0)
     ruby_parser (3.10.1)
       sexp_processor (~> 4.9)
@@ -347,7 +347,7 @@ GEM
     simple_calendar (2.2.7)
       rails (>= 3.0)
     simple_oauth (0.3.1)
-    simplecov (0.15.0)
+    simplecov (0.15.1)
       docile (~> 1.1.0)
       json (>= 1.8, < 3)
       simplecov-html (~> 0.10.0)
diff --git a/app/models/city.rb b/app/models/city.rb
index 9bf0cd0c4e546cb0dadf95ae3c0240f321cd035b..f21e95f39e81c4cdf43f9815c12a59a71a48f180 100644
--- a/app/models/city.rb
+++ b/app/models/city.rb
@@ -3,6 +3,4 @@
 # It is mainly used to manage coordinates
 #
 class City < ApplicationRecord
-  has_many :events, foreign_key: :city, primary_key: :name
-  has_many :orgas, foreign_key: :city, primary_key: :name
 end
diff --git a/app/models/kind.rb b/app/models/kind.rb
index 79a7d5753d9a803ec7bfe9a11f56c3422629de79..10e7a9e08cc8b45840c1f16ff6fe083f9adffb54 100644
--- a/app/models/kind.rb
+++ b/app/models/kind.rb
@@ -1,4 +1,4 @@
 # Gives the possibility to organise organisations! :)
 class Kind < ApplicationRecord
-  has_many :orgas
+  has_many :orgas, dependent: :destroy
 end
diff --git a/app/models/region.rb b/app/models/region.rb
index ef6fa540eac4d275878dcd2665705863013a7a2b..1c229c64eb75c2dee0aec2084e858aa0eca0b025 100644
--- a/app/models/region.rb
+++ b/app/models/region.rb
@@ -1,9 +1,9 @@
 # This is mostly to group events around a region
 class Region < ApplicationRecord
   belongs_to :region
-  has_many :regions
+  has_many :regions, dependent: :nullify
 
-  has_many :orgas
+  has_many :orgas, dependent: :destroy
 
   default_scope { order :name }
 
diff --git a/app/models/user.rb b/app/models/user.rb
index 39cbcf29c32920fee7e62023869ffe9ef410a142..41fd48db28f93a10aaccd490559b39270571bee5 100644
--- a/app/models/user.rb
+++ b/app/models/user.rb
@@ -8,8 +8,6 @@ class User < ApplicationRecord
   devise :database_authenticatable, authentication_keys: [:login]
   # :registerable, :validatable
 
-  has_many :notes
-
   validates :login, presence: true
 
   def encrypted_password=(pass)
diff --git a/db/seeds.rb b/db/seeds.rb
index 73d3a6cf016a2d2174ac7af74e0a96f338e5dc0d..6e6bced5d9f3bc1934a2970b85b077f2f8f0a28b 100644
--- a/db/seeds.rb
+++ b/db/seeds.rb
@@ -1,5 +1,3 @@
-# encoding: utf-8
-
 # This file should contain all the record creation needed to seed the database
 # with its default values.
 # The data can then be loaded with the rake db:seed (or created alongside the