Skip to content

Commit

Permalink
Update KotlinHybridViewManager.ts
Browse files Browse the repository at this point in the history
  • Loading branch information
mrousavy committed Jan 20, 2025
1 parent 140d816 commit c28da0b
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -167,8 +167,7 @@ void J${stateUpdaterName}::updateViewProps(jni::alias_ref<jni::JClass>,
jni::alias_ref<react::StateWrapperImpl::javaobject> stateWrapper) {
${JHybridTSpec}* view = javaView->cthis();
const react::State& state = stateWrapper->cthis()->getState();
// TODO: Can this be a static_cast?
const auto& concreteState = dynamic_cast<const ConcreteStateData&>(state);
const auto& concreteState = static_cast<const ConcreteStateData&>(state);
const ${stateClassName}& data = concreteState.getData();
const std::optional<${propsClassName}>& maybeProps = data.getProps();
if (!maybeProps.has_value()) {
Expand Down

0 comments on commit c28da0b

Please sign in to comment.