Skip to content

Commit 3a13d85

Browse files
authored
Update FlightSuretyData.sol
1 parent 06f907f commit 3a13d85

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

contracts/FlightSuretyData.sol

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ contract FlightSuretyData {
6060
public
6161
{
6262
contractOwner = msg.sender;
63+
6364
}
6465

6566
/********************************************************************************************/
@@ -262,14 +263,15 @@ contract FlightSuretyData {
262263
(
263264
address airline,
264265
address passenger,
265-
uint256 amount
266+
uint256 amount,
267+
uint256 creditRate
266268
)
267269
external
268270
requireIsOperational
269271

270272
{
271273
// Get expected amount to be credited
272-
uint256 required_amount =insurance[airline].amount.mul(3).div(2);
274+
uint256 required_amount =insurance[airline].amount.mul(creditRate).div(2);
273275

274276
require(insurance[airline].passenger == passenger, "Passenger is not insured");
275277
require(required_amount == amount, "The amount to be credited is not as espected");

0 commit comments

Comments
 (0)