#include <bits/stdc++.h>
using namespace std;
map<pair<int, int>, int> es;
int v[200000];
int main() {
  int n, m;
  scanf("%d %d", &n, &m);
  for (int i = 0; i < m; i++) {
    int a, b;
    scanf("%d %d", &a, &b);
    a--;
    b--;
    es[make_pair(a, b)] = 1;
    es[make_pair(b, a)] = 1;
  }
  for (int i = 0; i < n; i++) v[i] = i;
  for (int run = 0; run < 100; run++) {
    for (int i = 0; i < n; i++) {
      int rd = rand() % n;
      swap(v[i], v[rd]);
    }
    int yesCnt = 0;
    for (int i = 0; i < n; i++) {
      int next = (i + 1) % n;
      if (es.find(make_pair(v[i], v[next])) == es.end()) {
        yesCnt++;
      }
      if (yesCnt == m) break;
    }
    if (yesCnt == m) {
      yesCnt = 0;
      for (int i = 0; i < n; i++) {
        int next = (i + 1) % n;
        if (es.find(make_pair(v[i], v[next])) == es.end()) {
          yesCnt++;
          printf("%d %d\n", v[i] + 1, v[next] + 1);
        }
        if (yesCnt == m) break;
      }
      return 0;
    }
  }
  puts("-1");
  return 0;
}
