(webMode string, annotations whisk.KeyValueArr, entityName string, preserveAnnotations bool, existingAction *whisk.Action)
| 761 | } |
| 762 | |
| 763 | func webAction(webMode string, annotations whisk.KeyValueArr, entityName string, preserveAnnotations bool, existingAction *whisk.Action) (whisk.KeyValueArr, error) { |
| 764 | switch strings.ToLower(webMode) { |
| 765 | case "yes": |
| 766 | fallthrough |
| 767 | case "true": |
| 768 | return webActionAnnotations(preserveAnnotations, annotations, entityName, addWebAnnotations, existingAction) |
| 769 | case "no": |
| 770 | fallthrough |
| 771 | case "false": |
| 772 | return webActionAnnotations(preserveAnnotations, annotations, entityName, deleteWebAnnotations, existingAction) |
| 773 | case "raw": |
| 774 | return webActionAnnotations(preserveAnnotations, annotations, entityName, addRawAnnotations, existingAction) |
| 775 | default: |
| 776 | return nil, webInputError(webMode) |
| 777 | } |
| 778 | } |
| 779 | |
| 780 | type WebActionAnnotationMethod func(annotations whisk.KeyValueArr) whisk.KeyValueArr |
| 781 |
no test coverage detected