|
1 | 1 | /** |
2 | | - * @authors: [@unknownunknown1] |
| 2 | + * @authors: [@unknownunknown1*] |
3 | 3 | * @reviewers: [@ferittuncer*, @clesaege*, @satello*] |
4 | 4 | * @auditors: [] |
5 | 5 | * @bounties: [] |
@@ -182,22 +182,22 @@ contract Linguo is Arbitrable { |
182 | 182 | // **************************** // |
183 | 183 |
|
184 | 184 | /** @dev Creates a task based on provided details. Requires a value of maximal price to be deposited. |
185 | | - * @param _submissionTimeout Time allotted for submitting a translation. |
| 185 | + * @param _deadline The deadline for the translation to be completed. |
186 | 186 | * @param _minPrice A minimal price of the translation. In wei. |
187 | 187 | * @param _metaEvidence A URI of meta-evidence object for task submission. |
188 | 188 | * @return taskID The ID of the created task. |
189 | 189 | */ |
190 | 190 | function createTask( |
191 | | - uint _submissionTimeout, |
| 191 | + uint _deadline, |
192 | 192 | uint _minPrice, |
193 | 193 | string _metaEvidence |
194 | 194 | ) external payable returns (uint taskID){ |
195 | 195 | require(msg.value >= _minPrice, "Deposited value should be greater than or equal to the min price."); |
196 | | - require(_submissionTimeout > 0, "Submission timeout should not be 0."); |
| 196 | + require(_deadline > now, "The deadline should be in the future."); |
197 | 197 |
|
198 | 198 | taskID = tasks.length++; |
199 | 199 | Task storage task = tasks[taskID]; |
200 | | - task.submissionTimeout = _submissionTimeout; |
| 200 | + task.submissionTimeout = _deadline - now; |
201 | 201 | task.minPrice = _minPrice; |
202 | 202 | task.maxPrice = msg.value; |
203 | 203 | task.lastInteraction = now; |
|
0 commit comments