Ignore:
Timestamp:
Aug 3, 2013, 9:36:22 PM (6 years ago)
Author:
Stefan Schwarzer <sschwarzer@…>
Branch:
default
Message:
Make `encoding` available by forwarding to the internal file object.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • ftputil/file.py

    r1318 r1320  
    6363        # Overwritten later in `_open`.
    6464        self._bin_mode = None
    65         #TODO: Allow encoding to be set in `_open`.
    66         self._encoding = "utf-8"
    6765        self._conn = None
    6866        self._read_mode = None
     
    167165        delegate the requests to the contained file object.
    168166        """
    169         if attr_name in ("flush isatty fileno read readlines seek tell "
    170                          "truncate name softspace write writelines".split()):
     167        if attr_name in ("encoding flush isatty fileno read readlines seek "
     168                         "tell truncate name softspace write writelines".
     169                         split()):
    171170            return getattr(self._fo, attr_name)
    172171        raise AttributeError(
Note: See TracChangeset for help on using the changeset viewer.