MCPcopy Create free account
hub / github.com/fa0311/TwitterInternalAPIDocument / marge_feature_switch

Function marge_feature_switch

lib/graphql.py:101–113  ·  view source on GitHub ↗
(initial_output: dict)

Source from the content-addressed store, hash-verified

99
100
101def marge_feature_switch(initial_output: dict) -> dict:
102 featureSwitches = {}
103 for k in initial_output["featureSwitch"].keys():
104 if k == "debug":
105 for k in initial_output["featureSwitch"]["debug"].keys():
106 featureSwitches[k] = initial_output["featureSwitch"]["debug"][k]
107 if k == "defaultConfig":
108 for k in initial_output["featureSwitch"]["defaultConfig"].keys():
109 featureSwitches[k] = initial_output["featureSwitch"]["defaultConfig"][k]
110 if k == "user":
111 for k in initial_output["featureSwitch"]["user"].keys():
112 featureSwitches[k] = initial_output["featureSwitch"]["user"][k]
113 return featureSwitches
114
115
116def marge_metadata(graphql_output: list, feature_switch: dict) -> list:

Callers 1

generator.pyFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected