Changeset ad2b033f75151402c125239e7e9a155e62877e58

Show
Ignore:
Timestamp:
02/14/08 12:01:48 (11 months ago)
Author:
William McBrine <wmcbrine@gmail.com>
git-committer:
William McBrine <wmcbrine@gmail.com> 1203012108 -0500
git-parent:

[165d27727cfe9afafccf7cc593b96c53b0ebb38e]

git-author:
William McBrine <wmcbrine@gmail.com> 1203012108 -0500
Message:

Extraneous code, formatting.

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • plugins/video/video.py

    r165d277 rad2b033  
    2525    def pre_cache(self, full_path): 
    2626        if Video.video_file_filter(self, full_path): 
    27             return transcode.supported_format(full_path) 
    28         return False 
     27            transcode.supported_format(full_path) 
    2928 
    3029    def video_file_filter(self, full_path, type=None): 
  • pyTivo.py

    r165d277 rad2b033  
    1111for section, settings in config.getShares(): 
    1212    httpd.add_container(section, settings) 
    13     #Precaching of files: does a recursive list of base path 
     13    # Precaching of files: does a recursive list of base path 
    1414    if settings.get('precache', 'False').lower() == 'true': 
    1515        plugin = GetPlugin(settings.get('type')) 
    1616        if hasattr(plugin,'pre_cache'): 
    17             print "PreCaching the " + section + " share." 
     17            print 'Pre-caching the', section, 'share.' 
    1818            pre_cache_filter = getattr(plugin, 'pre_cache') 
    1919 
    2020            def build_recursive_list(path): 
    21                 files = [] 
    22                 for file in os.listdir(path): 
    23                     file = os.path.join(path, file) 
    24                     if os.path.isdir(file): 
    25                         files.extend(build_recursive_list(file)) 
    26                         continue 
    27                     pre_cache_filter(file) 
    28                 return files 
     21                for f in os.listdir(path): 
     22                    f = os.path.join(path, f) 
     23                    if os.path.isdir(f): 
     24                        build_recursive_list(f) 
     25                    else: 
     26                        pre_cache_filter(f) 
    2927 
    30             files = build_recursive_list(settings.get('path')) 
     28            build_recursive_list(settings.get('path')) 
    3129 
    3230b = beacon.Beacon() 
     
    3634    b.listen() 
    3735 
    38 print "pyTivo is ready." 
     36print 'pyTivo is ready.' 
    3937try: 
    4038    httpd.serve_forever()