pageflow 14.3.0 → 14.4.0

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


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

checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 2b1dccc2159c3f19167d16c7e852a0a0fd3ccd4a068f01e72c060ee2b60a5e1d
4
- data.tar.gz: 6a60400394872ee81248de6d251d41637630c56bacded5c9fd8b79d1f205a80b
3
+ metadata.gz: 83633ca0a4d539fe72289335da8fadc780b40861611367e6b457a8ea5021541a
4
+ data.tar.gz: 836e8c19598fe2f86ef5797baab839d27d884216b5de86f39a46606b1d427ff8
5
5
  SHA512:
6
- metadata.gz: 4efd4cea653cb672ef04f9bcb27cd3a0b15c64d9abb162eb9dc1d845eb350ec52f8dd4048c62638a9b48253897d1afe92e63ef9570f89419a6091c5c0df62339
7
- data.tar.gz: 7e8bd3b5cd259a41c69c52799ce1679b008cb48bdde5db83c94843d8316a4cc8faaf11bff6948ca1a6789eb32669b44c70525cc9b58995335350f41faee04696
6
+ metadata.gz: 05ef59f396f6726ec8022d9fcc2605600204c0e0554cf5b6c1514f7968303e09db7f2deab55e2a58da6902e254ef373e961adf888c531f3069409ad9bc56585a
7
+ data.tar.gz: bae10300d19ce28fe2ca218d091ee71ae9267a3c0d9f756596bb88d36a3532e75173dd1139484b0b9cc177ac3a7435dec7dc2504dda3c4895705e62aac266ddb
@@ -1,26 +1,16 @@
1
1
  # CHANGELOG
2
2
 
3
- ### Version 14.3.0
3
+ ### Version 14.4.0
4
4
 
5
- 2019-07-24
5
+ 2019-08-13
6
6
 
7
- [Compare changes](https://github.com/codevise/pageflow/compare/14-2-stable...v14.3.0)
7
+ [Compare changes](https://github.com/codevise/pageflow/compare/14-3-stable...v14.4.0)
8
8
 
9
- - Add text position center option
10
- ([#1183](https://github.com/codevise/pageflow/pull/1183))
11
- - Add `failed?` method to file models
12
- ([#1191](https://github.com/codevise/pageflow/pull/1191))
13
- - Structured data improvements
14
- ([#1189](https://github.com/codevise/pageflow/pull/1189))
15
- - Remove margin right of links in page text
16
- ([#1188](https://github.com/codevise/pageflow/pull/1188))
17
- - Add theme option for alternative content link icon
18
- ([#1184](https://github.com/codevise/pageflow/pull/1184))
19
- - Support CDN that redirects to HTTPS
20
- ([#1190](https://github.com/codevise/pageflow/pull/1190))
21
- - Bug fix: Prevent hiding links in credits menu
22
- ([#1182](https://github.com/codevise/pageflow/pull/1182))
9
+ - Fix entry membership create error
10
+ ([#1200](https://github.com/codevise/pageflow/pull/1200))
11
+ - Move meta data defaults to attribute reader
12
+ ([#1198](https://github.com/codevise/pageflow/pull/1198))
23
13
 
24
14
  See
25
- [14-2-stable branch](https://github.com/codevise/pageflow/blob/14-2-stable/CHANGELOG.md)
15
+ [14-3-stable branch](https://github.com/codevise/pageflow/blob/14-3-stable/CHANGELOG.md)
26
16
  for previous changes.
@@ -7,9 +7,9 @@ module Pageflow
7
7
 
8
8
  def meta_tags_data_for_entry(entry)
9
9
  {
10
- keywords: entry.keywords.presence || Pageflow.config.default_keywords_meta_tag,
11
- author: entry.author.presence || Pageflow.config.default_author_meta_tag,
12
- publisher: entry.publisher.presence || Pageflow.config.default_publisher_meta_tag
10
+ keywords: entry.keywords.presence,
11
+ author: entry.author.presence,
12
+ publisher: entry.publisher.presence
13
13
  }
14
14
  end
15
15
  end
@@ -11,7 +11,7 @@ module Pageflow
11
11
  foreign_key: 'entity_id',
12
12
  optional: true
13
13
 
14
- validates :user, :entity, :role, presence: true
14
+ validates :entity, :role, presence: true
15
15
  validates :user_id, uniqueness: {scope: [:entity_type, :entity_id]}
16
16
  validate :account_membership_exists, if: :on_entry?
17
17
  validates :role,
@@ -38,9 +38,8 @@ module Pageflow
38
38
  private
39
39
 
40
40
  def account_membership_exists
41
- unless user.accounts.include?(entity.account)
42
- errors[:base] << 'Entry Membership misses presupposed Membership on account of entry'
43
- end
41
+ errors[:base] << 'Entry Membership misses presupposed Membership on account of entry' if
42
+ user.present? && !user.accounts.include?(entity.account)
44
43
  end
45
44
 
46
45
  def on_entry?
@@ -97,6 +97,18 @@ module Pageflow
97
97
  self[:share_providers] || entry.theming.default_share_providers
98
98
  end
99
99
 
100
+ def author
101
+ read_attribute(:author) || Pageflow.config.default_author_meta_tag
102
+ end
103
+
104
+ def publisher
105
+ read_attribute(:publisher) || Pageflow.config.default_publisher_meta_tag
106
+ end
107
+
108
+ def keywords
109
+ read_attribute(:keywords) || Pageflow.config.default_keywords_meta_tag
110
+ end
111
+
100
112
  def active_share_providers
101
113
  share_providers.select { |_k, v| v }.keys
102
114
  end
@@ -351,6 +351,10 @@ de:
351
351
  attributes:
352
352
  folder:
353
353
  must_be_same_account: Ordner muss zu gleichem Konto gehören wie Beitrag
354
+ pageflow/membership:
355
+ attributes:
356
+ user:
357
+ required: Benutzer muss ausgewählt sein
354
358
  models:
355
359
  account:
356
360
  one: Konto
@@ -351,6 +351,10 @@ en:
351
351
  attributes:
352
352
  folder:
353
353
  must_be_same_account: Folder must belong to same account as story
354
+ pageflow/membership:
355
+ attributes:
356
+ user:
357
+ required: User must be selected
354
358
  models:
355
359
  account:
356
360
  one: Account
@@ -1,3 +1,3 @@
1
1
  module Pageflow
2
- VERSION = '14.3.0'.freeze
2
+ VERSION = '14.4.0'.freeze
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pageflow
3
3
  version: !ruby/object:Gem::Version
4
- version: 14.3.0
4
+ version: 14.4.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Codevise Solutions Ltd
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-07-24 00:00:00.000000000 Z
11
+ date: 2019-08-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails