Skip to content

Commit

Permalink
avoid redefining litcal_events by assigning it to a similar name var …
Browse files Browse the repository at this point in the history
…from admin.php
  • Loading branch information
JohnRDOrazio committed Oct 16, 2024
1 parent 608b19d commit 7d3f5ca
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion admin.php
Original file line number Diff line number Diff line change
Expand Up @@ -187,6 +187,6 @@ class="bi bi-exclamation-triangle-fill flex-shrink-0 me-2" viewBox="0 0 16 16"
<?php
$testsIndex = json_encode($LitCalTests);
$litcal_events = json_encode($LitCalAllFestivities);
echo "<script>const LitCalTests = Object.freeze($testsIndex); let litcal_events = Object.freeze($litcal_events);</script>";
echo "<script>const LitCalTests = Object.freeze($testsIndex); const LitcalEvents = Object.freeze($litcal_events);</script>";
include_once 'layout/footer.php';
?>
2 changes: 1 addition & 1 deletion assets/js/admin.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
* @global
* This variable is defined globally in the admin.php file, and can be updated in an API call.
*/
let litcal_events = litcal_events;
let litcal_events = LitcalEvents; // eslint-disable-line

/**
* Represents the DateTime format used for displaying full dates in the UTC timezone.
Expand Down

0 comments on commit 7d3f5ca

Please sign in to comment.