mirror of
				https://github.com/yt-dlp/yt-dlp.git
				synced 2025-10-31 14:45:14 +00:00 
			
		
		
		
	[utils] Correct octal/hexadecimal number detection in js_to_json
This commit is contained in:
		| @@ -712,6 +712,9 @@ class TestUtil(unittest.TestCase): | ||||
|         inp = '''{"foo":101}''' | ||||
|         self.assertEqual(js_to_json(inp), '''{"foo":101}''') | ||||
|  | ||||
|         inp = '''{"duration": "00:01:07"}''' | ||||
|         self.assertEqual(js_to_json(inp), '''{"duration": "00:01:07"}''') | ||||
|  | ||||
|     def test_js_to_json_edgecases(self): | ||||
|         on = js_to_json("{abc_def:'1\\'\\\\2\\\\\\'3\"4'}") | ||||
|         self.assertEqual(json.loads(on), {"abc_def": "1'\\2\\'3\"4"}) | ||||
|   | ||||
		Reference in New Issue
	
	Block a user
	 Yen Chi Hsuan
					Yen Chi Hsuan