mirror of
				https://github.com/avatao-content/baseimage-tutorial-framework
				synced 2025-11-04 12:42:55 +00:00 
			
		
		
		
	Improve InotifyEvent.__repr__
This commit is contained in:
		@@ -19,7 +19,7 @@ class InotifyEvent:
 | 
			
		||||
        return self.__repr__()
 | 
			
		||||
 | 
			
		||||
    def __repr__(self):
 | 
			
		||||
        return f'{self.date}\t{self.__class__.__name__}:\t{self.src_path}'
 | 
			
		||||
        return f'{self.__class__.__name__}({self.src_path})'
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
class InotifyMovedEvent(InotifyEvent):
 | 
			
		||||
@@ -28,7 +28,7 @@ class InotifyMovedEvent(InotifyEvent):
 | 
			
		||||
        super().__init__(src_path)
 | 
			
		||||
 | 
			
		||||
    def __repr__(self):
 | 
			
		||||
        return super().__repr__()+f'\t-> {self.dest_path}'
 | 
			
		||||
        return f'{self.__class__.__name__}({self.src_path}, {self.dest_path})'
 | 
			
		||||
 | 
			
		||||
 | 
			
		||||
class InotifyFileCreatedEvent(InotifyEvent):
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user