Fixed typo and added missing FileDescriptor type hinting to avoid possible non-object errors