Project

General

Profile

Actions

Bug #17670

closed

Fact upload fails if data is not valid JSON

Added by Lukas Zapletal over 7 years ago. Updated over 2 years ago.

Status:
Resolved
Priority:
Normal
Assignee:
-
Category:
Facts
Target version:
-
Difficulty:
Triaged:
No
Fixed in Releases:
Found in Releases:

Description

Erroring out with

$ curl -H "Accept:application/json,version=2" -H "Content-Type:application/json" -X POST -u admin:changeme -d '' http://localhost:3000/api/hosts/facts --insecure {
"error": {"message":"undefined method `[]' for nil:NilClass"}
}

easy fix. I will also improve documentation for this method.

Actions #1

Updated by The Foreman Bot over 7 years ago

  • Status changed from New to Ready For Testing
  • Pull request https://github.com/theforeman/foreman/pull/4110 added
Actions #2

Updated by The Foreman Bot almost 7 years ago

  • Status changed from Ready For Testing to New
  • Assignee deleted (Lukas Zapletal)
  • Pull request deleted (https://github.com/theforeman/foreman/pull/4110)
Actions #3

Updated by Adi Abramovitch over 2 years ago

  • Status changed from New to Resolved
Actions

Also available in: Atom PDF