OSEPP motor shield+dc motor+2 button direction control= inconsistent behavior

Hello all- cannot for the life of me figure out why this circuit will not drive the motor in either direction on button press. The code prints ‘FORWARD’ and ‘BACKWARD’ on corresponding button press and ‘IDK’ with no button press indicating that the logic is working but the motor does not turn at every press and sometimes when it does it stays running or runs in the opposite direction of button pressed. See attached image of circuit and code below

#include <AFMotor.h>
AF_DCMotor motor(4);

#include<Servo.h>
Servo servo;



const int ForwardPin = 2;
const int ReversePin = 4;   

void setup() {
  int ForwardState;
  int ReverseState;
  int ForwardState2;
  int ReverseState2;
  int ForwardDelta;
  int ReverseDelta;
  
  pinMode(ForwardPin, INPUT);
  pinMode(ReversePin, INPUT);
     
  Serial.begin(9600);           
  Serial.println("Motor test!");
  Serial.println("Hello World");

  
  motor.run(RELEASE);
  motor.setSpeed(500);

  servo.attach(1);
  
}
void loop() {
  
  int ForwardState = digitalRead(2);
  int ReverseState = digitalRead(4);
  delay(50);
  int ForwardState2 = digitalRead(2);
  int ReverseState2 = digitalRead(4);

  
  if (ForwardState == ForwardState2 || ReverseState == ReverseState2) {
        
   if  (ForwardState != HIGH || ReverseState != HIGH) {
    
    if (ForwardState != 1) {
      motor.run(FORWARD);
      motor.setSpeed(255);
      Serial.println("FORWARD");
  }
  
    else if (ReverseState != 1) {
      motor.run(BACKWARD);
      motor.setSpeed(255);
      Serial.println("BACKWARD");
  }
  
   
  }
    else {
    Serial.println("IDK");
    motor.run(RELEASE);
    }
  }
 }

Update in case some future person runs into the same problem with V1 motor shields- I replaced the OSEPP V1 shield with an Adafruit V2.3 and it works like a champ. Also inverted the button press logic from ‘!=HIGH’ to ‘==LOW’ don’t know if that would have made a difference on the other shield because I burned in a trash fire

#include <Wire.h>
#include <Adafruit_MotorShield.h>
#include "utility/Adafruit_MS_PWMServoDriver.h"

Adafruit_MotorShield AFMS = Adafruit_MotorShield(); 
Adafruit_DCMotor *motor = AFMS.getMotor(4);



const int ForwardPin = 2;
const int ReversePin = 4;   

void setup() {
  int ForwardState;
  int ReverseState;
  int ForwardState2;
  int ReverseState2;
  int ForwardDelta;
  int ReverseDelta;
  
  pinMode(ForwardPin, INPUT);
  pinMode(ReversePin, INPUT);
     
  Serial.begin(9600);           // set up Serial library at 9600 bps
  Serial.println("Motor test!");
  Serial.println("Hello World");

  AFMS.begin();
  motor->setSpeed(150);
    
  
}
void loop() {
  
  int ForwardState = digitalRead(2);
  int ReverseState = digitalRead(3);
  delay(50);
  int ForwardState2 = digitalRead(2);
  int ReverseState2 = digitalRead(3);

  
  if (ForwardState == ForwardState2 || ReverseState == ReverseState2) {
        
   if  (ForwardState != HIGH || ReverseState != HIGH) {
    
    if (ForwardState == LOW) {
      motor->run(FORWARD);
      motor->setSpeed(255);
      Serial.println("FORWARD");
  }
  
    else if (ReverseState == LOW) {
      motor->run(BACKWARD);
      motor->setSpeed(255);
      Serial.println("BACKWARD");
  }
  
   
  }
    else {
    Serial.println("IDK");
    motor->run(RELEASE);
    }
  }
 }