Create a safe version of the verion string. Needed so that we can distinguish between versions and sub-collections in URIs. I.e. we don't want adsense_v1.1 to refer to the '1' collection in the v1 version of the adsense api. Args: version: string, The version string.
(version)
| 169 | |
| 170 | |
| 171 | def safe_version(version): |
| 172 | """Create a safe version of the verion string. |
| 173 | |
| 174 | Needed so that we can distinguish between versions |
| 175 | and sub-collections in URIs. I.e. we don't want |
| 176 | adsense_v1.1 to refer to the '1' collection in the v1 |
| 177 | version of the adsense api. |
| 178 | |
| 179 | Args: |
| 180 | version: string, The version string. |
| 181 | Returns: |
| 182 | The string with '.' replaced with '_'. |
| 183 | """ |
| 184 | |
| 185 | return version.replace(".", "_") |
| 186 | |
| 187 | |
| 188 | def unsafe_version(version): |
no outgoing calls
no test coverage detected
searching dependent graphs…