mirror of
https://github.com/alextselegidis/easyappointments.git
synced 2024-12-21 06:02:23 +03:00
Fix PHP warning when fixing unavailabilities
This commit is contained in:
parent
3d6e3d8e1c
commit
0a36662272
1 changed files with 2 additions and 3 deletions
|
@ -104,9 +104,8 @@ class Caldav_sync
|
||||||
public function save_unavailability(array $unavailability, array $provider): ?string
|
public function save_unavailability(array $unavailability, array $provider): ?string
|
||||||
{
|
{
|
||||||
try {
|
try {
|
||||||
// If the unavailability is reccuring don't sync
|
if (str_contains((string) $unavailability['id_caldav_calendar'], 'RECURRENCE')) {
|
||||||
if (strpos($unavailability['id_caldav_calendar'], 'RECURRENCE') !== false) {
|
return $unavailability['id_caldav_calendar'] ?? null; // Do not sync recurring unavailabilities
|
||||||
return $unavailability['id_caldav_calendar'];
|
|
||||||
}
|
}
|
||||||
|
|
||||||
$ics_file = $this->get_unavailability_ics_file($unavailability, $provider);
|
$ics_file = $this->get_unavailability_ics_file($unavailability, $provider);
|
||||||
|
|
Loading…
Reference in a new issue