(self, string_1, string_2)
| 29 | CATEGORY = "PD Nodes" |
| 30 | |
| 31 | def join_strings(self, string_1, string_2): |
| 32 | # 核心逻辑:中间加一个换行符 \n |
| 33 | s1 = str(string_1) if string_1 is not None else "" |
| 34 | s2 = str(string_2) if string_2 is not None else "" |
| 35 | |
| 36 | # 如果第一项为空,直接返回第二项,避免头部出现空行 |
| 37 | if s1 == "": |
| 38 | return (s2,) |
| 39 | if s2 == "": |
| 40 | return (s1,) |
| 41 | |
| 42 | result = s1 + "\n" + s2 |
| 43 | return (result,) |
| 44 | |
| 45 | |
| 46 | class PD_StringLineCount: |
nothing calls this directly
no outgoing calls
no test coverage detected