protected function getResourceLocale(ResourceInterface $resource)
    {
        $sys = $resource->getSystemProperties();

        return $sys instanceof LocalizedResourceSystemProperties
            ? $sys->getLocale()
            : null;
    }
protected function getResourceLocale(ResourceInterface $resource)
    {
        $sys = $resource->getSystemProperties();

        return $sys instanceof LocalizedResourceSystemProperties
            ? $sys->getLocale()
            : null;
    }
@param ResourceInterface $resource

@return string|null