alias #fetch_rows to #each

This commit is contained in:
Brian Lopez 2010-03-30 09:15:04 -07:00
parent 1eef152459
commit 2810329190
1 changed files with 1 additions and 0 deletions

View File

@ -158,6 +158,7 @@ void Init_mysql_duce_ext() {
cMySQLResult = rb_define_class_under(mMySQL, "Result", rb_cObject);
rb_define_method(cMySQLResult, "fetch_row", rb_mysql_result_fetch_row, 0);
rb_define_method(cMySQLResult, "fetch_rows", rb_mysql_result_fetch_rows, -1);
rb_define_method(cMySQLResult, "each", rb_mysql_result_fetch_rows, -1);
#ifdef HAVE_RUBY_ENCODING_H
utf8Encoding = rb_enc_find_index("UTF-8");