为什么在mysqli db包装器中调用num_rows函数时会出现错误“未定义的属性:类中的mysqli :: $ num_rows”?

I have a mysqli db wrapper that looks like this:

class connector
{

public static $mysql;
public static $mysqlStmt;

static function connect()
{

        self::$mysqlStmt = self::$mysql = new mysqli("localhost", "root", "", "");

}


static function query($query)
{
    connector::connect();

    self::$mysql->query($query);

    return new self;
}

static function numrows()
{
    connector::connect();

    return (self::$mysql) ? self::$mysql->num_rows : false;
}
}

This class is extended by my other class called users. Calling the query function and executing a query to the database works perfectly. But however. When I call on the function numrows, I get this error

Undefined property: mysqli::$num_rows in connector

What am I doing wrong?