'NoneType' object is not subscriptabl

Looks like this is a duplicate of this post.