Skip to content

Commit

Permalink
On first run, make sure the settings are properly set.
Browse files Browse the repository at this point in the history
  • Loading branch information
steeve committed Oct 27, 2013
1 parent f4f97c4 commit cf423cb
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions resources/site-packages/xbmctorrent/index.py
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,14 @@
@ensure_fanart
@tracked(force=True)
def index():
import os
firstrun = os.path.join(plugin.addon.getAddonInfo("path"), ".firstrun")
if not os.path.exists(firstrun):
with open(firstrun, "w"):
# This doesn't get set properly
plugin.set_setting("encryption", "1")
plugin.open_settings()

for module in MODULES:
yield {
"label": module["name"],
Expand Down

0 comments on commit cf423cb

Please sign in to comment.