fat_free_crm 0.24.2 → 0.24.3

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.

Potentially problematic release.


This version of fat_free_crm might be problematic. Click here for more details.

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: e51023f054e1b4e27c80606a526908788ffb68cc97bfc926fca6e463fdf7112b
4
- data.tar.gz: f338a29d816c802acc2fbb3be38ed58fb05e16b6d2fa756261e17ae2541d8bda
3
+ metadata.gz: 12985fcc9a5bd872776d35ce530c83469607adbab241bc2750b1c7f3652c09f8
4
+ data.tar.gz: 1571d711121e35ca2990fccc54a936cbe10b3c15e260972f9274daf75f555f83
5
5
  SHA512:
6
- metadata.gz: 42a5e574664c72c5f897451431c3242edf8d78f816c03c3e9c7a82f3180ec3fb8643d26f14ad86df9637ecc78f9c8aa55e180846166b21af474c059f89095598
7
- data.tar.gz: 0e196d27fef2f8aa5f49796cba0eb913740442182bc03affc111a4cb963d4a53d79158be0d25cbef6558542d9ca10f42fd1d900a67e90274258ced48eb111f5c
6
+ metadata.gz: d932db7ffc1acf32f243e3d7dd59deef7e6cbcf1f206e18b88b804b8972ef2cd0832ef20fef631039b6a52246b15c09942271b0e805a826e866dd119556bd97b
7
+ data.tar.gz: c751929fbf6656aebea0937e8482c9c284f9c3ca9186019461ba6074904182e3a6ffd0a604965732403b2c76bf04600f03e773e64ae318d890c48a6e596c49cf
@@ -9,15 +9,15 @@
9
9
  # Configure ActionMailer unless running tests
10
10
  # ActionMailer is setup in test mode later on
11
11
  #
12
- unless Rails.env.test?
13
- require 'setting'
14
12
 
15
- smtp_settings = Setting.smtp || {}
13
+ Rails.application.config.after_initialize do
14
+ unless Rails.env.test?
15
+ smtp_settings = Setting.smtp || {}
16
16
 
17
- Rails.application.config.action_mailer.smtp_settings = smtp_settings.symbolize_keys if smtp_settings["address"].present?
17
+ Rails.application.config.action_mailer.smtp_settings = smtp_settings.symbolize_keys if smtp_settings["address"].present?
18
18
 
19
- if (host = Setting.host).present?
20
- (Rails.application.routes.default_url_options ||= {})[:host] = host.gsub('http://', '')
19
+ if (host = Setting.host).present?
20
+ (Rails.application.routes.default_url_options ||= {})[:host] = host.gsub('http://', '')
21
+ end
21
22
  end
22
-
23
23
  end
@@ -6,9 +6,9 @@
6
6
  # See MIT-LICENSE file or http://www.opensource.org/licenses/mit-license.php
7
7
  #------------------------------------------------------------------------------
8
8
  # Load field names for custom fields, for Ransack search
9
- require 'setting'
10
- if Setting.database_and_table_exists? && ActiveRecord::Base.connection.table_exists?(:custom_fields)
11
- Rails.application.config.after_initialize do
9
+
10
+ Rails.application.config.after_initialize do
11
+ if ActiveRecord::Base.connection.table_exists?(:custom_fields)
12
12
  I18n.backend.load_translations
13
13
 
14
14
  translations = { ransack: { attributes: {} } }
@@ -7,4 +7,6 @@
7
7
  #------------------------------------------------------------------------------
8
8
  # Set relative url root for assets
9
9
 
10
- ActionController::Base.relative_url_root = Setting.base_url if Setting.base_url.present?
10
+ Rails.application.config.after_initialize do
11
+ ActionController::Base.relative_url_root = Setting.base_url if Setting.base_url.present?
12
+ end
@@ -22,6 +22,10 @@
22
22
  # We should setup a secret token if FFCRM is running in application mode but NOT in engine mode.
23
23
  # This functionality has been extracted to lib so it can be tested.
24
24
  if FatFreeCRM.application?
25
- require 'fat_free_crm/secret_token_generator'
26
- FatFreeCRM::SecretTokenGenerator.setup!
25
+
26
+ Rails.application.config.after_initialize do
27
+ require 'fat_free_crm/secret_token_generator'
28
+
29
+ FatFreeCRM::SecretTokenGenerator.setup!
30
+ end
27
31
  end
Binary file
Binary file
Binary file
@@ -11,8 +11,8 @@ class ConvertToActiveStorage < ActiveRecord::Migration[5.2]
11
11
  else
12
12
  'LASTVAL()'
13
13
  end
14
- get_blob_id = 'LAST_INSERT_ROWID()' if conn.is_a?(SQLite3::Database)
15
- if conn.is_a?(::PG::Connection)
14
+ get_blob_id = 'LAST_INSERT_ROWID()' if Object.const_defined?("SQLite3") && conn.is_a?(SQLite3::Database)
15
+ if Object.const_defined?("PG") && conn.is_a?(::PG::Connection)
16
16
  get_blob_id = 'LASTVAL()'
17
17
  conn.prepare('active_storage_blobs', <<-SQL)
18
18
  INSERT INTO active_storage_blobs (
@@ -9,7 +9,7 @@ module FatFreeCRM
9
9
  module VERSION # :nodoc:
10
10
  MAJOR = 0
11
11
  MINOR = 24
12
- TINY = 2
12
+ TINY = 3
13
13
  PRE = nil
14
14
 
15
15
  STRING = [MAJOR, MINOR, TINY, PRE].compact.join('.')
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fat_free_crm
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.24.2
4
+ version: 0.24.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Michael Dvorkin