From 85fe77fe8052ff5c0f23f3449cd3f9fcecbd3f4f Mon Sep 17 00:00:00 2001 From: Arvind Date: Fri, 21 Jun 2013 20:04:23 +0530 Subject: [PATCH] Spec for sweet-maker is followed now in the coding style. --- sweetmaker.py | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/sweetmaker.py b/sweetmaker.py index 6396d37..4a4d411 100644 --- a/sweetmaker.py +++ b/sweetmaker.py @@ -1,18 +1,14 @@ import requests import json -def make(what, who, where, how): + +def sweet(sweet_url, what, who, where, how): sweet = {} sweet['what'] = what sweet['who'] = who sweet['where'] = where sweet['how'] = how sweet_list = [] - sweet_list.append(sweet) - return sweet_list - - -def send(sweet): - request = requests.api.post(SWEET_STORE_URL,{'data':json.dumps(sweet)}) + request = requests.api.post(sweet_url, {'data':json.dumps(sweet)}) if request.status_code == 200: return True else: -- 1.7.10.4