JulianEberius/SublimeRope — pull request #61 by jasonmyers (2013-01-15 19:02:59+00:00)
Title: Autoimport adds import below class definition if it has an import right above it

For example, after auto-import
```python
import ...

import logging
class Foo(object):
bar = datetime.datetime.utcnow()
```

becomes

```python
import ...

import logging
class Foo(object):
import datetime
bar = datetime.datetime.utcnow()
```

Due to the offset + 1 in autoimport.py. Removed the +1 and changed it to a '\n' before the import statement, so that ```import datetime``` moves above ```class Foo(object)```

Also fixed a regex bug that wasn't finding the first class/def since re.MULTILINE was not specified (it was always processing the whole file)