Skip to content

Commit

Permalink
Update email and team name on the Contact Us dashboard widget. (#758)
Browse files Browse the repository at this point in the history
  • Loading branch information
EarthlingDavey authored Oct 30, 2024
1 parent 1dd8630 commit 4fbf353
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions bin/composer-post-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,21 @@ if grep -q $TOTAL_POLL_SEARCH $TOTAL_POLL_FILE ; then
echo "Fixing syntax error in totalpoll-lite..."
sed -i "s/$TOTAL_POLL_SEARCH/$TOTAL_POLL_REPLACE/g" $TOTAL_POLL_FILE
fi


MOJ_COMPONENTS_FILE=/var/www/html/public/app/mu-plugins/wp-moj-components/component/Introduce/Introduce.php
MOJ_COMPONENTS_SEARCH_1="justice\.web@digital\.justice\.gov\.uk"
MOJ_COMPONENTS_REPLACE_1="[email protected]"
MOJ_COMPONENTS_SEARCH_2="Justice\son\sthe\sWeb\steam"
MOJ_COMPONENTS_REPLACE_2="Central Digital Product Team"

# If search string is in file. Then replace it.
if grep -q $MOJ_COMPONENTS_SEARCH_1 $MOJ_COMPONENTS_FILE ; then
echo "Replacing email text in wp-moj-components plugin."
sed -i "s/$MOJ_COMPONENTS_SEARCH_1/$MOJ_COMPONENTS_REPLACE_1/g" $MOJ_COMPONENTS_FILE
fi

if grep -q $MOJ_COMPONENTS_SEARCH_2 $MOJ_COMPONENTS_FILE ; then
echo "Replacing team text in wp-moj-components plugin."
sed -i "s/'$MOJ_COMPONENTS_SEARCH_2'/'$MOJ_COMPONENTS_REPLACE_2'/g" $MOJ_COMPONENTS_FILE
fi

0 comments on commit 4fbf353

Please sign in to comment.