Less nesting of timestamp data
This commit is contained in:
		
							parent
							
								
									aa2b18f3dd
								
							
						
					
					
						commit
						4f27157438
					
				
					 1 changed files with 5 additions and 7 deletions
				
			
		|  | @ -56,13 +56,11 @@ class RawinsObs(): | ||||||
| 
 | 
 | ||||||
|         now = datetime.datetime.now(datetime.UTC) |         now = datetime.datetime.now(datetime.UTC) | ||||||
| 
 | 
 | ||||||
|         return { |         return datetime.datetime( | ||||||
|             'timestamp': datetime.datetime( |             year  = now.year, | ||||||
|                 year  = now.year, |             month = now.month, | ||||||
|                 month = now.month, |             day   = day if day < 51 else day - 50 | ||||||
|                 day   = day if day < 51 else day - 50 |         ) | ||||||
|             ) |  | ||||||
|         } |  | ||||||
| 
 | 
 | ||||||
|     def parse_surface_pressure(self, value: str): |     def parse_surface_pressure(self, value: str): | ||||||
|         if value[0:2] == '99': |         if value[0:2] == '99': | ||||||
|  |  | ||||||
		Loading…
	
	Add table
		
		Reference in a new issue