<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def _check_scan_dir(self, fs, path, info, depth):
 # type: (FS, Text, Info, int) -> bool """Check if a directory contents should be scanned."""

        if self.max_depth is not None and depth >= self.max_depth:
            return False
        return self.check_scan_dir(fs, path, info)