{"action":"created","issue":{"url":"https://api.github.com/repos/aGlitch/Mario-64-Randomizer/issues/1","repository_url":"https://api.github.com/repos/aGlitch/Mario-64-Randomizer","labels_url":"https://api.github.com/repos/aGlitch/Mario-64-Randomizer/issues/1/labels{/name}","comments_url":"https://api.github.com/repos/aGlitch/Mario-64-Randomizer/issues/1/comments","events_url":"https://api.github.com/repos/aGlitch/Mario-64-Randomizer/issues/1/events","html_url":"https://github.com/aGlitch/Mario-64-Randomizer/issues/1","id":425763670,"node_id":"MDU6SXNzdWU0MjU3NjM2NzA=","number":1,"title":"Randomizing list bug","user":{"login":"TimeTravelPenguin","id":35803538,"node_id":"MDQ6VXNlcjM1ODAzNTM4","avatar_url":"https://avatars1.githubusercontent.com/u/35803538?v=4","gravatar_id":"","url":"https://api.github.com/users/TimeTravelPenguin","html_url":"https://github.com/TimeTravelPenguin","followers_url":"https://api.github.com/users/TimeTravelPenguin/followers","following_url":"https://api.github.com/users/TimeTravelPenguin/following{/other_user}","gists_url":"https://api.github.com/users/TimeTravelPenguin/gists{/gist_id}","starred_url":"https://api.github.com/users/TimeTravelPenguin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TimeTravelPenguin/subscriptions","organizations_url":"https://api.github.com/users/TimeTravelPenguin/orgs","repos_url":"https://api.github.com/users/TimeTravelPenguin/repos","events_url":"https://api.github.com/users/TimeTravelPenguin/events{/privacy}","received_events_url":"https://api.github.com/users/TimeTravelPenguin/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2019-03-27T04:52:27Z","updated_at":"2019-03-27T05:58:28Z","closed_at":null,"author_association":"NONE","body":"Heyo, I am just reviewing the code, and I found a bug when doing some general clean up. Nothing too complex, but the following line has an issue:\r\n\r\nIn `btnEnterSeed_Click`:\r\n```randomList = randomList.GetRange(0, Convert.ToInt32(nudStarAmount.Value));```\r\n\r\nIf `randomList` has less elements than `nudStarAmount.Value`, you will get `System.ArgumentException`.\r\n\r\nI am currently looking through the code, and it seems like an easy fix I can push shortly. "},"comment":{"url":"https://api.github.com/repos/aGlitch/Mario-64-Randomizer/issues/comments/476989490","html_url":"https://github.com/aGlitch/Mario-64-Randomizer/issues/1#issuecomment-476989490","issue_url":"https://api.github.com/repos/aGlitch/Mario-64-Randomizer/issues/1","id":476989490,"node_id":"MDEyOklzc3VlQ29tbWVudDQ3Njk4OTQ5MA==","user":{"login":"TimeTravelPenguin","id":35803538,"node_id":"MDQ6VXNlcjM1ODAzNTM4","avatar_url":"https://avatars1.githubusercontent.com/u/35803538?v=4","gravatar_id":"","url":"https://api.github.com/users/TimeTravelPenguin","html_url":"https://github.com/TimeTravelPenguin","followers_url":"https://api.github.com/users/TimeTravelPenguin/followers","following_url":"https://api.github.com/users/TimeTravelPenguin/following{/other_user}","gists_url":"https://api.github.com/users/TimeTravelPenguin/gists{/gist_id}","starred_url":"https://api.github.com/users/TimeTravelPenguin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/TimeTravelPenguin/subscriptions","organizations_url":"https://api.github.com/users/TimeTravelPenguin/orgs","repos_url":"https://api.github.com/users/TimeTravelPenguin/repos","events_url":"https://api.github.com/users/TimeTravelPenguin/events{/privacy}","received_events_url":"https://api.github.com/users/TimeTravelPenguin/received_events","type":"User","site_admin":false},"created_at":"2019-03-27T05:58:28Z","updated_at":"2019-03-27T05:58:28Z","author_association":"NONE","body":"Whoops, I forgot to output what I did in my previous comment!\r\n\r\nSimply, you had two lines of code in both the randomize seen and set seed button.\r\nI moved this buggy code into a new method, so it is more simple to alter and fix in possible future incidents.\r\n\r\n```\r\nif (randomList.Count >= nudStarAmount.Value)\r\n    {\r\n        randomList = randomList.GetRange(0, Convert.ToInt32(nudStarAmount.Value));\r\n    }\r\n```\r\n\r\nThe code was left unchanged but put into an if statement where, if `randomList` contains more stars than the number of starts the user wants to use in `nudStarAmount`, it will run. Otherwise, it will maintain and display the current list size, as it cannot possibly output more than it holds. Simple fix.\r\n\r\nOther than that, I am working on a bunch of cleanups to make the code much cleaner and futureproof to additional features. I am also interested in creating a more interactive interface, but this isn't the place for that discussion."}}
{"actor":{"display_login":"TimeTravelPenguin"}}