Spaces:
Running
Running
Update getvalues.py
Browse files- getvalues.py +6 -6
getvalues.py
CHANGED
@@ -24,7 +24,7 @@ def findTime(input):
|
|
24 |
# meridian = time_search.group(2)
|
25 |
return time
|
26 |
else:
|
27 |
-
return
|
28 |
|
29 |
# find number in the string input provided by the user
|
30 |
def findNumber(input):
|
@@ -32,7 +32,7 @@ def findNumber(input):
|
|
32 |
if number:
|
33 |
return number.group()
|
34 |
else:
|
35 |
-
return
|
36 |
|
37 |
# # find date in the string input provided by the user
|
38 |
def findDate(input):
|
@@ -40,7 +40,7 @@ def findDate(input):
|
|
40 |
if date:
|
41 |
return date.group()
|
42 |
else:
|
43 |
-
return
|
44 |
|
45 |
# find month in the string input provided by the user
|
46 |
def findMonth(input):
|
@@ -48,7 +48,7 @@ def findMonth(input):
|
|
48 |
if month:
|
49 |
return month.group()
|
50 |
else:
|
51 |
-
return
|
52 |
|
53 |
# find day in the string input provided by the user
|
54 |
def findDay(input):
|
@@ -56,14 +56,14 @@ def findDay(input):
|
|
56 |
if day:
|
57 |
return day.group()
|
58 |
else:
|
59 |
-
return
|
60 |
|
61 |
def findrepeat(input):
|
62 |
repeat = re.search(r'\b(daily|everyday|every week|every month|every sunday|every monday|every tuesday|every wednesday|every thursday|every friday|every saturday)\b', input)
|
63 |
if repeat:
|
64 |
return repeat.group()
|
65 |
else:
|
66 |
-
return
|
67 |
|
68 |
|
69 |
def getValues(query):
|
|
|
24 |
# meridian = time_search.group(2)
|
25 |
return time
|
26 |
else:
|
27 |
+
return None
|
28 |
|
29 |
# find number in the string input provided by the user
|
30 |
def findNumber(input):
|
|
|
32 |
if number:
|
33 |
return number.group()
|
34 |
else:
|
35 |
+
return None
|
36 |
|
37 |
# # find date in the string input provided by the user
|
38 |
def findDate(input):
|
|
|
40 |
if date:
|
41 |
return date.group()
|
42 |
else:
|
43 |
+
return None
|
44 |
|
45 |
# find month in the string input provided by the user
|
46 |
def findMonth(input):
|
|
|
48 |
if month:
|
49 |
return month.group()
|
50 |
else:
|
51 |
+
return None
|
52 |
|
53 |
# find day in the string input provided by the user
|
54 |
def findDay(input):
|
|
|
56 |
if day:
|
57 |
return day.group()
|
58 |
else:
|
59 |
+
return None
|
60 |
|
61 |
def findrepeat(input):
|
62 |
repeat = re.search(r'\b(daily|everyday|every week|every month|every sunday|every monday|every tuesday|every wednesday|every thursday|every friday|every saturday)\b', input)
|
63 |
if repeat:
|
64 |
return repeat.group()
|
65 |
else:
|
66 |
+
return None
|
67 |
|
68 |
|
69 |
def getValues(query):
|