Fix compilation error in Schedule.cpp when building for rn-iOS + Fabric (#1634)

Due to an early cherry-pick from a more recent facebook/react-native version > https://github.com/microsoft/react-native-macos/pull/1498
this broke.

In https://github.com/microsoft/react-native-macos/pull/1498 I must have only build for rn-iOS + Paper.
I think we need a CircleCI job now for rn-iOS + Fabric

Here is the fix.
- std::optional's function signature is has_value()
- where as folly::Optional used hasValue()

In packages/rn-tester I ran:
```
USE_FABRIC=1 pod install
```
And then build and launched the app
This commit is contained in:
Christoph Purrer 2023-01-12 21:54:35 +01:00 коммит произвёл GitHub
Родитель 400430adc9
Коммит 005ef5ceab
Не найден ключ, соответствующий данной подписи
Идентификатор ключа GPG: 4AEE18F83AFDEB23
1 изменённых файлов: 1 добавлений и 1 удалений

Просмотреть файл

@ -61,7 +61,7 @@ Scheduler::Scheduler(
contextContainer_->find<std::weak_ptr<RuntimeScheduler>>(
"RuntimeScheduler");
auto runtimeScheduler =
(enableCallImmediates && weakRuntimeScheduler.hasValue())
(enableCallImmediates && weakRuntimeScheduler.has_value())
? weakRuntimeScheduler.value().lock()
: nullptr;