fix dangling reference issue
This commit is contained in:
		@@ -275,11 +275,10 @@ class RGB(Extension):
 | 
				
			|||||||
        if 0 <= index <= self.num_pixels - 1:
 | 
					        if 0 <= index <= self.num_pixels - 1:
 | 
				
			||||||
            for pixels in self.pixels:
 | 
					            for pixels in self.pixels:
 | 
				
			||||||
                if index <= (len(pixels) - 1):
 | 
					                if index <= (len(pixels) - 1):
 | 
				
			||||||
 | 
					                    pixels[index] = rgb
 | 
				
			||||||
                    break
 | 
					                    break
 | 
				
			||||||
                index -= len(pixels)
 | 
					                index -= len(pixels)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
            pixels[index] = rgb
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
            if not self.disable_auto_write:
 | 
					            if not self.disable_auto_write:
 | 
				
			||||||
                pixels.show()
 | 
					                pixels.show()
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user