mirror of
				https://git.collinwebdesigns.de/oscar.krause/fastapi-dls.git
				synced 2025-10-26 18:05:28 +03:00 
			
		
		
		
	fixes
This commit is contained in:
		
							parent
							
								
									059a51fe74
								
							
						
					
					
						commit
						0ab5969d3a
					
				| @ -84,7 +84,7 @@ class Lease(Base): | |||||||
| 
 | 
 | ||||||
|     def serialize(self, renewal_period: float, renewal_delta: timedelta) -> dict: |     def serialize(self, renewal_period: float, renewal_delta: timedelta) -> dict: | ||||||
|         lease_renewal = int(Lease.calculate_renewal(renewal_period, renewal_delta).total_seconds()) |         lease_renewal = int(Lease.calculate_renewal(renewal_period, renewal_delta).total_seconds()) | ||||||
|         lease_renewal = self.lease_created + relativedelta(seconds=lease_renewal) |         lease_renewal = self.lease_updated + relativedelta(seconds=lease_renewal) | ||||||
| 
 | 
 | ||||||
|         return { |         return { | ||||||
|             'lease_ref': self.lease_ref, |             'lease_ref': self.lease_ref, | ||||||
| @ -173,7 +173,7 @@ class Lease(Base): | |||||||
|         """ |         """ | ||||||
|         renew = delta.total_seconds() * renewal_period |         renew = delta.total_seconds() * renewal_period | ||||||
|         renew = timedelta(seconds=renew) |         renew = timedelta(seconds=renew) | ||||||
|         return delta - renew |         return renew | ||||||
| 
 | 
 | ||||||
| 
 | 
 | ||||||
| def init(engine: Engine): | def init(engine: Engine): | ||||||
|  | |||||||
		Loading…
	
		Reference in New Issue
	
	Block a user
	 Oscar Krause
						Oscar Krause