think_feel_do_engine 3.22.5 → 3.22.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 317b55c39071afb8de65112ed61dec117f7400cc
4
- data.tar.gz: 59557e6150938be5dd1d9c9f704a626f460d04fc
3
+ metadata.gz: 3cc18dda2e33d1bc41a9c39c3c230bd24aa99acc
4
+ data.tar.gz: 868fad56f2417c9d9e397c4afc4af9519adf0891
5
5
  SHA512:
6
- metadata.gz: 49ffe01220f3d58a27e42fee0195b9413a1414ac0d63f80999181ea50f083a8e09f6b415fa14fb18981ea02204cced45026e7019a08a1b8bb4fe0aae3948bbd3
7
- data.tar.gz: 971be377f7f578bf142fdc2d04d6b4a7ac1f157b7e032ad1f050fa689a0ab415f44f888ed0b8661c691cee40c5dbcfb17c5b69728813f419741409336f916dcc
6
+ metadata.gz: 850b1c5090b80484ac3862a59dba1b2c6571fe03fa8e337dc97193642aff23272d696de1a3a24faab7119437020d5c283d1d2f028a7c312f6819de90c4683550
7
+ data.tar.gz: 1c156da8b9a449141ecc2ec93c60a4908303150fa50535fe61d54121c2e032b380fb67fcc374224aa586b887846a7aae2662b0aaed8bcc2c343cf014f6cc38d8
@@ -17,12 +17,20 @@ module ThinkFeelDoEngine
17
17
  compose_path: new_coach_group_message_path(@group)
18
18
  }
19
19
  )
20
+
21
+ rescue ActiveRecord::RecordNotFound
22
+ redirect_to coach_group_messages_url(@group),
23
+ alert: "Unable to find Message with id #{params[:id]}"
20
24
  end
21
25
 
22
26
  private
23
27
 
24
28
  def set_group
25
29
  @group = Group.find(params[:group_id])
30
+
31
+ rescue ActiveRecord::RecordNotFound
32
+ redirect_to main_app.root_url,
33
+ alert: "Unable to find Group with id #{params[:group_id]}"
26
34
  end
27
35
  end
28
36
  end
@@ -1,9 +1,10 @@
1
1
  # frozen_string_literal: true
2
2
  # The name given to an Activity. Can be private to a Participant or public.
3
3
  class ActivityType < ActiveRecord::Base
4
+ MAX_TITLE_LENGTH = 1000
4
5
  belongs_to :participant
5
6
  has_many :activities, dependent: :restrict_with_exception
6
7
 
7
- validates :title, presence: true
8
+ validates :title, presence: true, length: { maximum: MAX_TITLE_LENGTH }
8
9
  # do not validate presence of participant
9
10
  end
@@ -0,0 +1,5 @@
1
+ class IncreaseCharacterLimitForActivityTypeTitle < ActiveRecord::Migration
2
+ def change
3
+ change_column :activity_types, :title, :string, limit: 1000
4
+ end
5
+ end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
  # nodoc
3
3
  module ThinkFeelDoEngine
4
- VERSION = "3.22.5"
4
+ VERSION = "3.22.6"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: think_feel_do_engine
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.22.5
4
+ version: 3.22.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eric Carty-Fickes
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-09-01 00:00:00.000000000 Z
11
+ date: 2016-12-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails
@@ -968,6 +968,7 @@ files:
968
968
  - db/migrate/20160616162347_convert_slide_options.rb
969
969
  - db/migrate/20160616201120_convert_event_payloads.rb
970
970
  - db/migrate/20160712153753_create_think_feel_do_engine_sms_delivery_errors.rb
971
+ - db/migrate/20161219024939_increase_character_limit_for_activity_type_title.rb
971
972
  - lib/tasks/lesson_notifications.rake
972
973
  - lib/tasks/seed.rake
973
974
  - lib/tasks/think_feel_do_engine_tasks.rake
@@ -1008,7 +1009,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
1008
1009
  version: '0'
1009
1010
  requirements: []
1010
1011
  rubyforge_project:
1011
- rubygems_version: 2.6.4
1012
+ rubygems_version: 2.6.7
1012
1013
  signing_key:
1013
1014
  specification_version: 4
1014
1015
  summary: Summary of ThinkFeelDoEngine.