Skip to content

Commit b1c6057

Browse files
authored
Merge pull request #18 from localgovdrupal/master
Release preparation for 1.0.0-alpha4
2 parents d2e31dd + f07dd5f commit b1c6057

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

.github/workflows/test.yml

+8-1
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,11 @@ jobs:
1212
runs-on: ubuntu-latest
1313

1414
steps:
15+
- name: setup PHP
16+
uses: shivammathur/setup-php@v2
17+
with:
18+
php-version: '7.4'
19+
1520
- name: Clone drupal_container
1621
uses: actions/checkout@v2
1722
with:
@@ -22,7 +27,9 @@ jobs:
2227
run: composer create-project --stability dev localgovdrupal/localgov-project html
2328

2429
- name: Setup package source for the test target
25-
run: composer --working-dir=html config repositories.1 vcs [email protected]:${{ github.repository }}.git
30+
run: |
31+
composer --working-dir=html config repositories.1 vcs [email protected]:${{ github.repository }}.git
32+
composer global config github-oauth.github.com ${{ github.token }}
2633
2734
- name: Extract Git branch name outside of a pull request
2835
if: github.event_name != 'pull_request'

modules/localgov_subsites_paragraphs/localgov_subsites_paragraphs.module

+1-1
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ function localgov_subsites_paragraphs_preprocess_paragraph(&$variables) {
146146
$file_url = File::load($fid)->getFileUri();
147147
$variables['background_url'] = ImageStyle::load('large_21_9')->buildUrl($file_url);
148148
}
149-
$heading_text = $paragraph->get('localgov_header_text')->value;
149+
$heading_text = $paragraph->get('localgov_header_text')->value ?: '';
150150
$heading_level = $paragraph->get('localgov_heading_level')->value ?: 'h2';
151151
$variables['heading'] = _localgov_subsites_paragraphs_create_heading($heading_text, $heading_level);
152152
$variables['colour_theme'] = $paragraph->get('localgov_colour_theme')->value;

0 commit comments

Comments
 (0)