{"action":"created","issue":{"url":"https://api.github.com/repos/easymodo/qimgv/issues/28","labels_url":"https://api.github.com/repos/easymodo/qimgv/issues/28/labels{/name}","comments_url":"https://api.github.com/repos/easymodo/qimgv/issues/28/comments","events_url":"https://api.github.com/repos/easymodo/qimgv/issues/28/events","html_url":"https://github.com/easymodo/qimgv/issues/28","id":109315797,"number":28,"title":"qimgv doesn't open image files without extension","user":{"login":"sevoan","id":4908055,"avatar_url":"https://avatars.githubusercontent.com/u/4908055?v=3","gravatar_id":"","url":"https://api.github.com/users/sevoan","html_url":"https://github.com/sevoan","followers_url":"https://api.github.com/users/sevoan/followers","following_url":"https://api.github.com/users/sevoan/following{/other_user}","gists_url":"https://api.github.com/users/sevoan/gists{/gist_id}","starred_url":"https://api.github.com/users/sevoan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sevoan/subscriptions","organizations_url":"https://api.github.com/users/sevoan/orgs","repos_url":"https://api.github.com/users/sevoan/repos","events_url":"https://api.github.com/users/sevoan/events{/privacy}","received_events_url":"https://api.github.com/users/sevoan/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-10-01T14:50:03Z","updated_at":"2015-10-01T18:37:57Z","closed_at":"2015-10-01T18:37:57Z","body":"Seems like this code doesn't work\r\n``` cpp\r\nfileType FileInfo::guessType() {\r\n    QString ext = getExtension(fileInfo.filePath());\r\n    if(ext == \"webm\" || ext == \"gifv\") { // case sensitivity?\r\n        return VIDEO;\r\n    }\r\n\r\n    QFile file(fileInfo.filePath());\r\n    file.open(QIODevice::ReadOnly);\r\n    //read first 2 bytes to determine file format\r\n    QByteArray startingBytes= file.read(2).toHex();\r\n    file.close();\r\n\r\n    if(startingBytes==\"4749\") {\r\n\r\n        return GIF;\r\n    }\r\n    else {\r\n        return STATIC;\r\n    }\r\n}\r\n```\r\nSteps to reproduce: Open program, press ctrl+o, select image file without extension. Voila! Nothing happened."},"comment":{"url":"https://api.github.com/repos/easymodo/qimgv/issues/comments/144811893","html_url":"https://github.com/easymodo/qimgv/issues/28#issuecomment-144811893","issue_url":"https://api.github.com/repos/easymodo/qimgv/issues/28","id":144811893,"user":{"login":"easymodo","id":5484275,"avatar_url":"https://avatars.githubusercontent.com/u/5484275?v=3","gravatar_id":"","url":"https://api.github.com/users/easymodo","html_url":"https://github.com/easymodo","followers_url":"https://api.github.com/users/easymodo/followers","following_url":"https://api.github.com/users/easymodo/following{/other_user}","gists_url":"https://api.github.com/users/easymodo/gists{/gist_id}","starred_url":"https://api.github.com/users/easymodo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/easymodo/subscriptions","organizations_url":"https://api.github.com/users/easymodo/orgs","repos_url":"https://api.github.com/users/easymodo/repos","events_url":"https://api.github.com/users/easymodo/events{/privacy}","received_events_url":"https://api.github.com/users/easymodo/received_events","type":"User","site_admin":false},"created_at":"2015-10-01T18:37:57Z","updated_at":"2015-10-01T18:37:57Z","body":"fixed"}}