Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
This is a bit of an edge case, but an easy fix. In user_stats.admin.inc, Line 41, we have:
'#options' => $options,
Instead, we should be using:
'#options' => isset($options) ? $options : array(),
$options can be undefined if node_type_get_types() returns no available content types. In this case, we'll receive a PHP warning.