@forcecalendar/core 2.1.37 → 2.1.38

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.
@@ -148,8 +148,8 @@ export class Event {
148
148
  if (!attendee.email || !attendee.name) {
149
149
  throw new Error(`Attendee at index ${index} must have email and name`);
150
150
  }
151
- // Validate email format
152
- const emailRegex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
151
+ // Validate email format (linear-time regex, no backtracking)
152
+ const emailRegex = /^[^\s@]+@[^\s@.]+\.[^\s@]+$/;
153
153
  if (!emailRegex.test(attendee.email)) {
154
154
  throw new Error(`Invalid email for attendee: ${attendee.email}`);
155
155
  }
@@ -919,7 +919,7 @@ export class Event {
919
919
  * @returns {boolean} True if email is valid
920
920
  */
921
921
  _isValidEmail(email) {
922
- const emailRegex = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
922
+ const emailRegex = /^[^\s@]+@[^\s@.]+\.[^\s@]+$/;
923
923
  return emailRegex.test(email);
924
924
  }
925
925
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@forcecalendar/core",
3
- "version": "2.1.37",
3
+ "version": "2.1.38",
4
4
  "type": "module",
5
5
  "private": false,
6
6
  "description": "A modern, lightweight, framework-agnostic calendar engine optimized for Salesforce",