Commit db3f7c4
committed
cmd/mr_discussion: populate PositionOptions when needed
With commit 4d1dbfa ("cmd/mr_discussion.go: Switch from NotePosition to
PositionOptions") the PositionOptions object was being created
regardless the presence of --position in user's command, causing the
REST API to fail due to the presence of a "position" parameter in the
request without all required arguments. This commit creates the
PositionOptions object within the --position handler, ensuring it's not
passed "empty".
Signed-off-by: Bruno Meneguele <[email protected]>1 parent 493268e commit db3f7c4
1 file changed
+6
-7
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
121 | 121 | | |
122 | 122 | | |
123 | 123 | | |
124 | | - | |
| 124 | + | |
125 | 125 | | |
126 | 126 | | |
127 | 127 | | |
| |||
150 | 150 | | |
151 | 151 | | |
152 | 152 | | |
153 | | - | |
| 153 | + | |
154 | 154 | | |
155 | 155 | | |
156 | 156 | | |
| |||
165 | 165 | | |
166 | 166 | | |
167 | 167 | | |
| 168 | + | |
| 169 | + | |
168 | 170 | | |
169 | 171 | | |
170 | 172 | | |
171 | 173 | | |
| 174 | + | |
172 | 175 | | |
173 | | - | |
174 | | - | |
175 | | - | |
176 | | - | |
177 | | - | |
| 176 | + | |
178 | 177 | | |
179 | 178 | | |
180 | 179 | | |
| |||
0 commit comments