Changeset 832 for SHX/trunk


Ignore:
Timestamp:
11/07/12 15:45:08 (8 years ago)
Author:
marcus
Message:
  • fixed support for readonly inventory
File:
1 edited

Legend:

Unmodified
Added
Removed
  • SHX/trunk/SeismicHandler/modules/stations.py

    r810 r832  
    256256 
    257257        # init db session only if necessary 
    258         if create and self.dbsessions.get(db, None) is None: 
     258        if self.dbsessions.get(db, None) is None: 
    259259            engine = sa.create_engine(db) 
    260260 
    261             tabledata = Base.metadata 
    262             tabledata.create_all(engine) 
     261            if create: 
     262                tabledata = Base.metadata 
     263                tabledata.create_all(engine) 
    263264 
    264265            Session = orm.sessionmaker(bind=engine) 
Note: See TracChangeset for help on using the changeset viewer.