mirror of
				https://github.com/Instadapp/yield-contract.git
				synced 2024-07-29 21:47:29 +00:00 
			
		
		
		
	Removed payable from unused functions
This commit is contained in:
		
							parent
							
								
									b73c7be2e1
								
							
						
					
					
						commit
						c21c942d25
					
				|  | @ -149,13 +149,13 @@ contract PoolToken is ReentrancyGuard, DSMath, ERC20Pausable { | ||||||
|       emit LogWithdraw(tknAmt, _burnAmt); |       emit LogWithdraw(tknAmt, _burnAmt); | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     function addInsurance(uint tknAmt) external payable { |     function addInsurance(uint tknAmt) external { | ||||||
|       baseToken.safeTransferFrom(msg.sender, address(this), tknAmt); |       baseToken.safeTransferFrom(msg.sender, address(this), tknAmt); | ||||||
|       insuranceAmt += tknAmt; |       insuranceAmt += tknAmt; | ||||||
|       emit LogAddInsurance(tknAmt); |       emit LogAddInsurance(tknAmt); | ||||||
|     } |     } | ||||||
| 
 | 
 | ||||||
|     function withdrawInsurance(uint tknAmt) external payable { |     function withdrawInsurance(uint tknAmt) external { | ||||||
|       require(msg.sender == instaIndex.master(), "not-master"); |       require(msg.sender == instaIndex.master(), "not-master"); | ||||||
|       require(tknAmt <= insuranceAmt || tknAmt == uint(-1), "not-enough-insurance"); |       require(tknAmt <= insuranceAmt || tknAmt == uint(-1), "not-enough-insurance"); | ||||||
|       if (tknAmt == uint(-1)) { |       if (tknAmt == uint(-1)) { | ||||||
|  |  | ||||||
|  | @ -148,7 +148,7 @@ contract PoolToken is ReentrancyGuard, ERC20Pausable, DSMath { | ||||||
|     emit LogAddInsurance(tknAmt); |     emit LogAddInsurance(tknAmt); | ||||||
|   } |   } | ||||||
| 
 | 
 | ||||||
|   function withdrawInsurance(uint tknAmt) external payable { |   function withdrawInsurance(uint tknAmt) external { | ||||||
|     require(msg.sender == instaIndex.master(), "not-master"); |     require(msg.sender == instaIndex.master(), "not-master"); | ||||||
|     require(tknAmt <= insuranceAmt || tknAmt == uint(-1), "not-enough-insurance"); |     require(tknAmt <= insuranceAmt || tknAmt == uint(-1), "not-enough-insurance"); | ||||||
|     if (tknAmt == uint(-1)) { |     if (tknAmt == uint(-1)) { | ||||||
|  |  | ||||||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 Thrilok Kumar
						Thrilok Kumar