summaryrefslogtreecommitdiff
path: root/src/leap/util
diff options
context:
space:
mode:
authorkali <kali@leap.se>2013-06-17 04:46:06 +0900
committerkali <kali@leap.se>2013-06-19 23:59:33 +0900
commitb36fe9cf87bc1917abc0667756f01e6d4609cc4c (patch)
tree0aa4d769aaf426b10d1ef7e325dea0e3643da7fc /src/leap/util
parent332f4fe1338b72eaa7bc2a2878ce30129004319e (diff)
install missing files during linux initialization
Closes: #2247, #2761
Diffstat (limited to 'src/leap/util')
-rw-r--r--src/leap/util/__init__.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/leap/util/__init__.py b/src/leap/util/__init__.py
index 41358d38..5ceaede5 100644
--- a/src/leap/util/__init__.py
+++ b/src/leap/util/__init__.py
@@ -37,3 +37,13 @@ except ImportError:
pass
__full_version__ = __appname__ + '/' + str(__version__)
+
+
+def first(things):
+ """
+ Return the head of a collection.
+ """
+ try:
+ return things[0]
+ except TypeError:
+ return None